This commit is contained in:
X1627315083
2025-09-12 14:58:07 +08:00
parent f760478594
commit 1df3458ac5
20 changed files with 85 additions and 57 deletions

View File

@@ -328,6 +328,9 @@ const handleToolClick = (tool) => {
style="width: 0; height: 0; opacity: 0" style="width: 0; height: 0; opacity: 0"
/> />
<slot name="customToolsTop" :tool-button-props="{ activeTool, canUndo, canRedo }" />
<ToolButton <ToolButton
v-for="tool in toolsList" v-for="tool in toolsList"
:key="tool.id" :key="tool.id"
@@ -339,7 +342,7 @@ const handleToolClick = (tool) => {
/> />
<!-- 自定义工具栏按钮插槽 --> <!-- 自定义工具栏按钮插槽 -->
<slot name="customTools" :tool-button-props="{ activeTool, canUndo, canRedo }" /> <slot name="customToolsBottom" :tool-button-props="{ activeTool, canUndo, canRedo }" />
</div> </div>
</template> </template>

View File

@@ -1043,9 +1043,12 @@ defineExpose({
@zoom-out="zoomOut" @zoom-out="zoomOut"
@undo-redo-status-changed="changeCanvas" @undo-redo-status-changed="changeCanvas"
> >
<template #customToolsTop="{ toolTopProps }">
<slot name="customToolsTop" :tool-button-props="toolTopProps" />
</template>
<!-- 扩展插槽 --> <!-- 扩展插槽 -->
<template #customTools="{ toolButtonProps }"> <template #customToolsBottom="{ toolButtonProps }">
<slot name="customTools" :tool-button-props="toolButtonProps" /> <slot name="customToolsBottom" :tool-button-props="toolButtonProps" />
</template> </template>
</ToolsSidebar> </ToolsSidebar>
</div> </div>

View File

@@ -218,7 +218,7 @@ const isShowLeft = ref(true);
</template> </template>
<!-- 使用插槽添加自定义工具栏按钮 --> <!-- 使用插槽添加自定义工具栏按钮 -->
<template #customTools="{ toolButtonProps }"> <template #customToolsBottom="{ toolButtonProps }">
<!-- 分隔线 --> <!-- 分隔线 -->
<div class="tool-separator"></div> <div class="tool-separator"></div>

View File

@@ -16,11 +16,12 @@
imageMode:'contains', imageMode:'contains',
}" }"
ref="editCanvas"> ref="editCanvas">
<template #customTools="{ toolButtonProps }">
<template #customToolsBottom="{ toolButtonProps }">
<!-- 也可以直接使用普通的按钮 --> <!-- 也可以直接使用普通的按钮 -->
<div class="custom-tool-btn" :class="{active:currentView === 'redGreenExample'}" @click="editFront('redGreenExample')"> <div class="custom-tool-btn" :class="{active:currentView === 'redGreenExample'}" @click="editFront('redGreenExample')">
<i class="fi fi-sr-layers"></i> <i class="fi fi-sr-layers"></i>
<div class="tool-tooltip">Edit the front and back sections</div> <div class="tool-tooltip">{{ $t('Canvas.editFrontBack') }}</div>
</div> </div>
</template> </template>
</editCanvas> </editCanvas>
@@ -42,6 +43,13 @@
imageMode:'contains', imageMode:'contains',
}" }"
ref="editCanvasBackFront"> ref="editCanvasBackFront">
<template #customToolsTop="{ toolTopProps }">
<!-- 也可以直接使用普通的按钮 -->
<div class="custom-tool-btn" @click="()=>currentView = 'canvasEditor'">
<i class="fi fi-ss-arrow-small-left" style="font-size: 3.5rem;"></i>
<div class="tool-tooltip">{{ $t('Canvas.back') }}</div>
</div>
</template>
<template #customTools="{ toolButtonProps }"> <template #customTools="{ toolButtonProps }">
<div class="custom-tool-btn" :class="{active:currentView === 'redGreenExample'}" @click="editFront('canvasEditor')"> <div class="custom-tool-btn" :class="{active:currentView === 'redGreenExample'}" @click="editFront('canvasEditor')">
<i class="fi fi-sr-layers"></i> <i class="fi fi-sr-layers"></i>
@@ -117,6 +125,7 @@ export default defineComponent({
},{immediate: true}) },{immediate: true})
provide('isShowMark',detailData.isShowMark) provide('isShowMark',detailData.isShowMark)
provide('canvasType',detailData.canvasType) provide('canvasType',detailData.canvasType)
const editFront = (str:any)=>{//编辑前后片 const editFront = (str:any)=>{//编辑前后片
let canvasJSON = '' as any let canvasJSON = '' as any

View File

@@ -122,10 +122,11 @@ export default defineComponent({
padding: 1rem; padding: 1rem;
text-align: center; text-align: center;
border-radius: .5rem; border-radius: .5rem;
// border: 1px dashed #202020; border: 1px solid #000;
border: 1px dashed transparent; // border: 1px dashed transparent;
border-radius: 1.5rem;
background: linear-gradient(#fff, #fff) padding-box,repeating-linear-gradient(-45deg,#fff 0,#fff 0.3em, #000 0,#000 0.6em); background: linear-gradient(#fff, #fff) padding-box,repeating-linear-gradient(-45deg,#fff 0,#fff 0.3em, #000 0,#000 0.6em);
margin-bottom: 3rem; margin-bottom: 1.4rem;
display: flex; display: flex;
flex-wrap: wrap; flex-wrap: wrap;
overflow: hidden; overflow: hidden;

View File

@@ -100,11 +100,12 @@ export default defineComponent({
padding: 1rem 0; padding: 1rem 0;
text-align: center; text-align: center;
border-radius: .5rem; border-radius: .5rem;
// border: 1px dashed #202020; border: 1px solid #000;
border: 1px dashed transparent; // border: 1px dashed transparent;
border-radius: 1.5rem;
position: relative; position: relative;
background: linear-gradient(#fff, #fff) padding-box,repeating-linear-gradient(-45deg,#fff 0,#fff 0.3em, #000 0,#000 0.6em); background: linear-gradient(#fff, #fff) padding-box,repeating-linear-gradient(-45deg,#fff 0,#fff 0.3em, #000 0,#000 0.6em);
margin-bottom: 3rem; margin-bottom: 1.4rem;
> img{ > img{
width: 100%; width: 100%;
height: 100%; height: 100%;

View File

@@ -105,9 +105,9 @@ export default defineComponent({
align-content: flex-start; align-content: flex-start;
&::-webkit-scrollbar{display: none;} &::-webkit-scrollbar{display: none;}
> .content_img_item{ > .content_img_item{
width: calc((50% - 1rem));
> .content_img_item_block{ > .content_img_item_block{
width: calc((34rem - 2rem) / 2); aspect-ratio: 1/1;
height: calc((34rem - 2rem) / 2);
position: relative; position: relative;
margin-bottom: 2rem; margin-bottom: 2rem;
@@ -119,16 +119,6 @@ export default defineComponent({
} }
} }
} }
> .material_content_list_loding{
width: 100%;
height: calc((34rem - 2rem) / 2);
}
> .upload_item{
width: calc((34rem - 2rem) / 2);
height: calc((34rem - 2rem) / 2);
align-items: center;
justify-content: center;
}
} }
} }

View File

@@ -349,9 +349,9 @@ export default defineComponent({
align-content: flex-start; align-content: flex-start;
&::-webkit-scrollbar{display: none;} &::-webkit-scrollbar{display: none;}
> .content_img_item{ > .content_img_item{
width: calc((50% - 1rem));
> .content_img_item_block{ > .content_img_item_block{
width: calc((34rem - 2rem) / 2); aspect-ratio: 1/1;
height: calc((34rem - 2rem) / 2);
position: relative; position: relative;
margin-bottom: 2rem; margin-bottom: 2rem;
cursor: pointer; cursor: pointer;
@@ -364,7 +364,7 @@ export default defineComponent({
} }
> .material_content_list_loding{ > .material_content_list_loding{
width: 100%; width: 100%;
height: calc((34rem - 2rem) / 2); aspect-ratio: 1/1;
overflow: hidden; overflow: hidden;
> img{ > img{
width: 100%; width: 100%;

View File

@@ -1,6 +1,6 @@
<template> <template>
<div class="selectList"> <div class="selectList">
<div class="selectList_header"> <div class="selectList_header" :class="{'element': type == 'element'}">
<div class="switch_type_list" v-if="type != 'element'"> <div class="switch_type_list" v-if="type != 'element'">
<div <div
@click.stop="openCurrent()" @click.stop="openCurrent()"
@@ -161,10 +161,16 @@ export default defineComponent({
height: auto; height: auto;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
border-radius: 1.5rem;
border: 1px solid #000;
padding: 1rem;
> .selectList_header{ > .selectList_header{
margin-bottom: 2.5rem; margin-bottom: 2.5rem;
display: flex; display: flex;
align-items: center; align-items: center;
&.element{
margin-bottom: 0rem;
}
> .switch_type_list{ > .switch_type_list{
display: flex; display: flex;
> .switch_type_item:last-child{ > .switch_type_item:last-child{

View File

@@ -199,9 +199,9 @@ export default defineComponent({
align-content: flex-start; align-content: flex-start;
&::-webkit-scrollbar{display: none;} &::-webkit-scrollbar{display: none;}
> .content_img_item{ > .content_img_item{
width: calc((50% - 1rem));
> .content_img_item_block{ > .content_img_item_block{
width: calc((34rem - 2rem) / 2); aspect-ratio: 1/1;
height: calc((34rem - 2rem) / 2);
position: relative; position: relative;
margin-bottom: 2rem; margin-bottom: 2rem;
@@ -215,11 +215,11 @@ export default defineComponent({
} }
> .material_content_list_loding{ > .material_content_list_loding{
width: 100%; width: 100%;
height: calc((34rem - 2rem) / 2); aspect-ratio: 1/1;
} }
> .upload_item{ > .upload_item{
width: calc((34rem - 2rem) / 2); width: calc((50% - 1rem));
height: calc((34rem - 2rem) / 2); aspect-ratio: 1/1;
align-items: center; align-items: center;
justify-content: center; justify-content: center;
} }

View File

@@ -262,9 +262,10 @@ import sketchCategory from "@/component/HomePage/sketchCategory.vue";
align-content: flex-start; align-content: flex-start;
&::-webkit-scrollbar{display: none;} &::-webkit-scrollbar{display: none;}
> .content_img_item{ > .content_img_item{
width: calc((50% - 1rem));
> .content_img_item_block{ > .content_img_item_block{
width: calc((34rem - 2rem) / 2); width: 100%;
height: calc((34rem - 2rem) / 2); aspect-ratio: 1/1;
position: relative; position: relative;
margin-bottom: 2rem; margin-bottom: 2rem;
margin: 1rem; margin: 1rem;
@@ -279,11 +280,11 @@ import sketchCategory from "@/component/HomePage/sketchCategory.vue";
} }
> .material_content_list_loding{ > .material_content_list_loding{
width: 100%; width: 100%;
height: calc((34rem - 2rem) / 2); aspect-ratio: 1/1;
} }
> .upload_item{ > .upload_item{
width: calc((34rem - 2rem) / 2); width: calc((50% - 1rem));
height: calc((34rem - 2rem) / 2); aspect-ratio: 1/1;
align-items: center; align-items: center;
justify-content: center; justify-content: center;
.upload{ .upload{

View File

@@ -145,9 +145,9 @@ export default defineComponent({
align-content: flex-start; align-content: flex-start;
&::-webkit-scrollbar{display: none;} &::-webkit-scrollbar{display: none;}
> .content_img_item{ > .content_img_item{
width: calc((50% - 1rem));
> .content_img_item_block{ > .content_img_item_block{
width: calc((34rem - 2rem) / 2); aspect-ratio: 1/1;
height: calc((34rem - 2rem) / 2);
position: relative; position: relative;
margin-bottom: 2rem; margin-bottom: 2rem;
@@ -174,11 +174,11 @@ export default defineComponent({
} }
> .material_content_list_loding{ > .material_content_list_loding{
width: 100%; width: 100%;
height: calc((34rem - 2rem) / 2); aspect-ratio: 1/1;
} }
> .upload_item{ > .upload_item{
width: calc((34rem - 2rem) / 2); width: calc((50% - 1rem));
height: calc((34rem - 2rem) / 2); aspect-ratio: 1/1;
align-items: center; align-items: center;
justify-content: center; justify-content: center;
.upload{ .upload{

View File

@@ -120,11 +120,11 @@ export default defineComponent({
height: 23.5rem; height: 23.5rem;
padding: 1rem; padding: 1rem;
text-align: center; text-align: center;
border-radius: .5rem; border: 1px solid #000;
// border: 1px dashed #202020; // border: 1px dashed transparent;
border: 1px dashed transparent; border-radius: 1.5rem;
background: linear-gradient(#fff, #fff) padding-box,repeating-linear-gradient(-45deg,#fff 0,#fff 0.3em, #000 0,#000 0.6em); background: linear-gradient(#fff, #fff) padding-box,repeating-linear-gradient(-45deg,#fff 0,#fff 0.3em, #000 0,#000 0.6em);
margin-bottom: 3rem; margin-bottom: 1.4rem;
display: flex; display: flex;
flex-wrap: wrap; flex-wrap: wrap;
overflow: hidden; overflow: hidden;

View File

@@ -126,11 +126,12 @@ export default defineComponent({
padding: 1rem 0; padding: 1rem 0;
text-align: center; text-align: center;
border-radius: .5rem; border-radius: .5rem;
// border: 1px dashed #202020; border: 1px solid #000;
border: 1px dashed transparent; // border: 1px dashed transparent;
border-radius: 1.5rem;
position: relative; position: relative;
background: linear-gradient(#fff, #fff) padding-box,repeating-linear-gradient(-45deg,#fff 0,#fff 0.3em, #000 0,#000 0.6em); background: linear-gradient(#fff, #fff) padding-box,repeating-linear-gradient(-45deg,#fff 0,#fff 0.3em, #000 0,#000 0.6em);
margin-bottom: 3rem; margin-bottom: 1.4rem;
> img{ > img{
width: 100%; width: 100%;
height: 100%; height: 100%;

View File

@@ -9,7 +9,7 @@
imageMode:'contains', imageMode:'contains',
}" }"
> >
<template #customTools="{ toolButtonProps }"> <template #customToolsBottom="{ toolButtonProps }">
<div class="custom-tool-btn" :class="{active:isHiddenModel}" @click="setHiddenmodel()"> <div class="custom-tool-btn" :class="{active:isHiddenModel}" @click="setHiddenmodel()">
<i class="fi fi-rr-eye"></i> <i class="fi fi-rr-eye"></i>
<div class="tool-tooltip">Hidden model</div> <div class="tool-tooltip">Hidden model</div>

View File

@@ -1277,6 +1277,8 @@ export default {
SelectTextColor:'选择文字颜色', SelectTextColor:'选择文字颜色',
SelectBGColor:'选择背景颜色', SelectBGColor:'选择背景颜色',
ok:'确定', ok:'确定',
editFrontBack:'编辑服装前片后片',
back:'返回',
}, },
speedList:{ speedList:{
High:'高级', High:'高级',

View File

@@ -1279,6 +1279,8 @@ export default {
SelectTextColor:'Select Text Color', SelectTextColor:'Select Text Color',
SelectBGColor:'Select Background Color', SelectBGColor:'Select Background Color',
ok:'OK', ok:'OK',
editFrontBack:'Edit the front and back sections',
back:'Back',
}, },
speedList:{ speedList:{
High:'High', High:'High',

View File

@@ -263,9 +263,10 @@ const userHabit : Module<UserHabit,RootState> = {
* 7 学校管理员 * 7 学校管理员
* 8 学校子账号 * 8 学校子账号
*/ */
// data.systemUser = 0
state.userDetail.affiliate = data.affiliate state.userDetail.affiliate = data.affiliate
state.userDetail.systemUser = data.systemUser state.userDetail.systemUser = data.systemUser
// state.userDetail.systemUser = 3 // state.userDetail.systemUser = 1
// 身份列表1可以使用aida系统2:可以使用affiliate页面3系统管理员用户 // 身份列表1可以使用aida系统2:可以使用affiliate页面3系统管理员用户
state.userDetail.systemList = [] state.userDetail.systemList = []
if(data.systemUser != 0)state.userDetail.systemList.push(1) if(data.systemUser != 0)state.userDetail.systemList.push(1)

View File

@@ -240,7 +240,7 @@
</div> </div>
</div> </div>
</div> </div>
<div class="userSystem" v-if="userDetail.systemList.indexOf(1) == -1"> <div class="userSystem" v-if="pastDuePage">
{{$t('Header.pastDue')}} {{$t('Header.pastDue')}}
</div> </div>
<div class="router" v-else-if="!getLangIsShowMark"> <div class="router" v-else-if="!getLangIsShowMark">
@@ -317,6 +317,7 @@ export default defineComponent({
const route = useRoute() const route = useRoute()
const router = useRouter() const router = useRouter()
const homeMainData = reactive({ const homeMainData = reactive({
leftShow:false, leftShow:false,
openType:'', openType:'',
openTypeChild:'', openTypeChild:'',
@@ -341,6 +342,14 @@ export default defineComponent({
}, },
bathGenerationList:["poseTransfer","SERIES_DESIGN","toProduct","relight"] bathGenerationList:["poseTransfer","SERIES_DESIGN","toProduct","relight"]
}) })
let userDetail= computed(()=>{
return store.state.UserHabit.userDetail
})
const pastDuePage = computed(()=>{
const isAllowedRoute = route.path === '/home/events' || route.path === '/home/works';
const hasNoSystemAccess = userDetail.value.systemList.indexOf(1) === -1;
return hasNoSystemAccess && !isAllowedRoute;
})
watch(()=>homeMainData.userDetailLanguage,(newVal)=>{ watch(()=>homeMainData.userDetailLanguage,(newVal)=>{
if(locale.value == newVal || !newVal)return if(locale.value == newVal || !newVal)return
locale.value = newVal locale.value = newVal
@@ -413,9 +422,7 @@ export default defineComponent({
// homeMainData.historyData.page = 1 // homeMainData.historyData.page = 1
// }) // })
let userDetail= computed(()=>{
return store.state.UserHabit.userDetail
})
let isMurmur = ref() let isMurmur = ref()
let credits = computed(()=>{ let credits = computed(()=>{
return store.state.UserHabit.credits.value return store.state.UserHabit.credits.value
@@ -791,6 +798,7 @@ export default defineComponent({
t, t,
...toRefs(homeMainData), ...toRefs(homeMainData),
...toRefs(historyData), ...toRefs(historyData),
pastDuePage,
locale, locale,
isMurmur, isMurmur,
credits, credits,

View File

@@ -10,7 +10,7 @@
<div v-show="!isScroll" class="modal_title_text_assistant gallery_btn white" :class="{active:'NewYear_2025' == worksSelect}" @click="setWorksSelect({value:'NewYear_2025'})">NewYear_2025</div> <div v-show="!isScroll" class="modal_title_text_assistant gallery_btn white" :class="{active:'NewYear_2025' == worksSelect}" @click="setWorksSelect({value:'NewYear_2025'})">NewYear_2025</div>
</div> --> </div> -->
<div class="page_content" ref="autoscrollDom"> <div class="page_content" ref="autoscrollDom">
<Falls ref="fall" @loadend="isShowMark = false" :itemWidth="failWidth" @setPortfolioLike="setPortfolioLike" :isScroll="isScroll" @getImgScale="getImgScale"></Falls> <Falls ref="fall" :key="getListDate.getLikePortfolio || getListDate.getMyPortfolio" @loadend="isShowMark = false" :itemWidth="failWidth" @setPortfolioLike="setPortfolioLike" :isScroll="isScroll" @getImgScale="getImgScale"></Falls>
<div class="page_loading_box" v-show="!isNoData"> <div class="page_loading_box" v-show="!isNoData">
<span class="page_loading" v-show="!isShowMark"></span> <span class="page_loading" v-show="!isShowMark"></span>
<span v-show="isShowMark"> <span v-show="isShowMark">