|
@@ -1,3 +1,4 @@
|
|
|
+import { CloudUploadOutlined } from "@ant-design/icons-vue";
|
|
|
import { css, cx } from "@linaria/core";
|
|
|
import { Button, Tooltip } from "ant-design-vue";
|
|
|
import { computed, reactive } from "vue";
|
|
@@ -5,8 +6,8 @@ import { computed, reactive } from "vue";
|
|
|
import {
|
|
|
IconAi,
|
|
|
IconApplication,
|
|
|
- IconCloud,
|
|
|
IconImage,
|
|
|
+ IconShape,
|
|
|
IconText,
|
|
|
IconTpl,
|
|
|
IconVideo,
|
|
@@ -16,7 +17,9 @@ import { defineUI } from "queenjs";
|
|
|
import { CompTree } from "../SliderRight/CompTree";
|
|
|
import AiText from "./AiText";
|
|
|
import Application from "./Application";
|
|
|
+import Comp3d from "./Comp3d";
|
|
|
import CustomComps from "./CustomComps";
|
|
|
+import Shapes from "./Shapes";
|
|
|
import { Sources } from "./Sources";
|
|
|
import Templates from "./Templates";
|
|
|
import Text from "./Text";
|
|
@@ -54,11 +57,11 @@ const tabs = [
|
|
|
component: Sources,
|
|
|
props: { sourceType: "Image", sourceFrom: "system" },
|
|
|
},
|
|
|
- // {
|
|
|
- // title: "形状",
|
|
|
- // icon: IconShape,
|
|
|
- // component: Shapes,
|
|
|
- // },
|
|
|
+ {
|
|
|
+ title: "形状",
|
|
|
+ icon: IconShape,
|
|
|
+ component: Shapes,
|
|
|
+ },
|
|
|
{
|
|
|
title: "视频",
|
|
|
icon: IconVideo,
|
|
@@ -70,9 +73,14 @@ const tabs = [
|
|
|
icon: IconApplication,
|
|
|
component: Application,
|
|
|
},
|
|
|
+ {
|
|
|
+ title: "3D",
|
|
|
+ icon: IconCube,
|
|
|
+ component: Comp3d,
|
|
|
+ },
|
|
|
{
|
|
|
title: "已上传",
|
|
|
- icon: IconCloud,
|
|
|
+ icon: CloudUploadOutlined,
|
|
|
content: [
|
|
|
{
|
|
|
title: "图片",
|
|
@@ -103,7 +111,7 @@ export default defineUI({
|
|
|
// @ts-ignore
|
|
|
const state = reactive({
|
|
|
tabIndex: 0,
|
|
|
- compIndexs: [0, 0, 0, 0, 0, 0, 0],
|
|
|
+ compIndexs: [0, 0, 0, 0, 0, 0, 0, 0, 0],
|
|
|
currentTab: computed(() => {
|
|
|
return tabs[state.tabIndex];
|
|
|
}),
|
|
@@ -120,7 +128,7 @@ export default defineUI({
|
|
|
|
|
|
return (
|
|
|
<div class="h-full flex">
|
|
|
- <div class="flex flex-col w-70px py-16px border-right !border-2px">
|
|
|
+ <div class="flex flex-col w-70px py-10px border-right !border-2px overflow-hidden">
|
|
|
{tabs.map((record, index) => {
|
|
|
return (
|
|
|
<>
|
|
@@ -129,7 +137,7 @@ export default defineUI({
|
|
|
key={index}
|
|
|
class={cx(
|
|
|
tabItem,
|
|
|
- "relative mt-10px py-8px text-center cursor-pointer text-light-50 transition",
|
|
|
+ "relative my-5px text-center cursor-pointer text-light-50 transition",
|
|
|
state.tabIndex == index && "active"
|
|
|
)}
|
|
|
onClick={() => (state.tabIndex = index)}
|
|
@@ -173,18 +181,22 @@ export default defineUI({
|
|
|
});
|
|
|
|
|
|
const tabItem = css`
|
|
|
+ &:before {
|
|
|
+ content: "";
|
|
|
+ position: absolute;
|
|
|
+ left: 0;
|
|
|
+ top: 0;
|
|
|
+ height: 100%;
|
|
|
+ width: 3px;
|
|
|
+ background-color: transparent;
|
|
|
+ transition: all 0.3s ease-in-out;
|
|
|
+ }
|
|
|
+ &.active,
|
|
|
&:hover {
|
|
|
color: @inf-primary-color;
|
|
|
}
|
|
|
&.active {
|
|
|
- color: @inf-primary-color;
|
|
|
&:before {
|
|
|
- content: "";
|
|
|
- position: absolute;
|
|
|
- left: 0;
|
|
|
- top: 0;
|
|
|
- height: 100%;
|
|
|
- width: 3px;
|
|
|
background-color: @inf-primary-color;
|
|
|
}
|
|
|
}
|