Merge branch 'dev_vite' of http://18.167.251.121:10003/aidlab/aida_front into dev_vite
This commit is contained in:
@@ -1066,6 +1066,7 @@ export class CanvasManager {
|
||||
angle: v.angle,
|
||||
name: v.sourceData.name,
|
||||
priority: v.sourceData.priority,
|
||||
gap: [0, 0],
|
||||
}
|
||||
if(obj.ifSingle){
|
||||
let left = (v.left - (flLeft - flWidth * flScaleX / 2));
|
||||
@@ -1092,6 +1093,7 @@ export class CanvasManager {
|
||||
obj.scale = [scaleXY, scaleXY];
|
||||
obj.angle = angle;
|
||||
obj.location = [left, top];
|
||||
obj.gap = [fill_.gapX, fill_.gapY];
|
||||
}
|
||||
if(obj.level2Type === "Pattern"){
|
||||
prints.push(obj);
|
||||
|
||||
@@ -329,6 +329,12 @@ const otherData = {
|
||||
|
||||
<template>
|
||||
<div class="app-container-example">
|
||||
<div id="test" style="position: fixed;
|
||||
width: 500px; height: 500px;
|
||||
top: 0;
|
||||
left: 0;
|
||||
z-index: 9999999;"><pingpu
|
||||
url="/src/assets/images/canvas/yinhua1.jpg" /></div>
|
||||
<!-- 模拟左侧导航栏 -->
|
||||
<!-- <div
|
||||
class="app-wrapper-btns"
|
||||
|
||||
34
src/component/Canvas/pingpu.vue
Normal file
34
src/component/Canvas/pingpu.vue
Normal file
@@ -0,0 +1,34 @@
|
||||
<template>
|
||||
<div class="pingpu" ref="el"><canvas ref="canvasRef"></canvas></div>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import {
|
||||
defineComponent,
|
||||
ref,
|
||||
reactive,
|
||||
nextTick,
|
||||
toRefs,
|
||||
inject,
|
||||
watch,
|
||||
computed,
|
||||
} from "vue";
|
||||
const props = defineProps({
|
||||
url: { type: String, required: true },
|
||||
positionX: { type: Number, default: 0 },// px
|
||||
positionY: { type: Number, default: 0 },// px
|
||||
angle: { type: Number, default: 0 },// 角度
|
||||
size: { type: Number, default: 100 },// %
|
||||
gapX: { type: Number, default: 0 },// px
|
||||
gapY: { type: Number, default: 0 },// px
|
||||
});
|
||||
console.log("==========", props);
|
||||
</script>
|
||||
|
||||
<style lang='less' scoped>
|
||||
.pingpu {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background-color: #f00;
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user