Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix/styles review: resolve style-panel/media/grid-column-panel styles reviews #924

Merged
merged 17 commits into from
Dec 13, 2024
Merged
Show file tree
Hide file tree
Changes from 5 commits
Commits
Show all changes
17 commits
Select commit Hold shift + click to select a range
31dcf0d
fix(style-review): resolve the style-panel styles review;
betterdancing Dec 4, 2024
5ef1864
fix(style-review): resolve the style-panel styles review
betterdancing Dec 4, 2024
a80c39b
fix(style-review): resolve the style-panel styles review
betterdancing Dec 5, 2024
540223f
fix(style-review): resolve the style-panel styles review
betterdancing Dec 5, 2024
6e079d5
Merge branch 'refactor/develop' of https://github.com/betterdancing/t…
betterdancing Dec 5, 2024
0bed41f
fix(style-review): resolve the style-panel styles review
betterdancing Dec 5, 2024
628c020
fix(style-panel): modify settings panel label color & some reviews
betterdancing Dec 6, 2024
13378f6
Merge branch 'refactor/develop' of https://github.com/betterdancing/t…
betterdancing Dec 6, 2024
3f64e3d
fix(style-panel): modify settings panel label color & some reviews
betterdancing Dec 6, 2024
9a03f5e
fix(style-panel): modify some reviews & color variables & Align lables
betterdancing Dec 9, 2024
2b7122d
fix(style-panel): modify some reviews;
betterdancing Dec 9, 2024
16dc0d2
fix(style-panel): modify some review
betterdancing Dec 10, 2024
8371dc1
fix(style): modify some reviews;
betterdancing Dec 11, 2024
9973d04
Merge branch 'refactor/develop' of https://github.com/betterdancing/t…
betterdancing Dec 11, 2024
0d422de
fix(style-panel): modify some reviews
betterdancing Dec 11, 2024
3d977a5
fix(style-panel): modify some reviews
betterdancing Dec 11, 2024
6e95cb8
fix(style-panel): resolve the code conflict
betterdancing Dec 13, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions designer-demo/public/mock/bundle.json
Original file line number Diff line number Diff line change
Expand Up @@ -9823,8 +9823,7 @@
},
"description": {
"zh_CN": "单元格编辑渲染配置项,也可以是函数 Function(h, params)"
},
"labelPosition": "left"
betterdancing marked this conversation as resolved.
Show resolved Hide resolved
}
},
{
"property": "filter",
Expand Down
14 changes: 11 additions & 3 deletions packages/common/component/MetaListItem.vue
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@
:popper-class="['option-popper', { 'fixed-left': expand }]"
:visible-arrow="!expand"
title=""
width="267"
width="295"
height="706"
trigger="manual"
@hide="hide(item)"
>
Expand Down Expand Up @@ -295,14 +296,21 @@ export default {
}
}
}

.tiny-popover {
position: relative;
.icon-close {
float: right;
position: absolute;
top: 6px;
right: 6px;
}
}
.add-options {
overflow-y: scroll;
height: 100%;
padding: 20px 0 20px 2px;
&.top {
margin-bottom: 0;
}
&::-webkit-scrollbar-track-piece {
background: var(--ti-lowcode-toolbar-bg);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<div v-for="(slot, index) in slotList" :key="slot.name" class="use-slot">
<div class="use-slot-item-name">
{{ slot.name }}
<tiny-tooltip effect="dark" :content="state.currentComponent?.content" placement="top">
<tiny-tooltip effect="dark" :content="state.currentComponent?.content" placement="bottom" width="260">
<span class="item-icon">
<component :is="state.currentComponent?.icon"></component>
</span>
Expand Down Expand Up @@ -74,7 +74,7 @@ export default {
TinyGrid: {
content:
'暴露给插槽使用的变量,为解构的参数,可以使用多个用逗号分隔,如:row(行数据),column(列数据),$table(内部表格实例),seq(序号),cell(单元格),columnIndex(列索引),rowIndex(行索引)',
icon: SvgICons['IconUnknow']()
icon: SvgICons['IconHelpCircle']()
}
}

Expand Down Expand Up @@ -202,6 +202,7 @@ export default {

.use-slot-item-content {
display: flex;
justify-content: space-between;
}

.use-slot-switch-wrap {
Expand All @@ -227,6 +228,7 @@ export default {

.slot-name-form-item {
margin-bottom: 0;
margin-right: 6px;
}

.item-icon {
Expand All @@ -240,6 +242,7 @@ export default {
position: relative;
font-size: 14px;
line-height: 20px;
width: 40px;
betterdancing marked this conversation as resolved.
Show resolved Hide resolved
height: 20px;
vertical-align: middle;
cursor: pointer;
Expand All @@ -262,7 +265,7 @@ export default {
.e__switch-core::after {
content: '';
position: absolute;
top: 1px;
top: 2px;
left: 1px;
border-radius: 100%;
transition: all 0.3s;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,6 @@ const change = (item) => {
background-color: var(--te-common-bg-container);
line-height: 14px;
min-width: 20px;
max-width: 80px;
color: var(--te-common-text-weaken);

&:hover {
Expand Down Expand Up @@ -238,8 +237,18 @@ const change = (item) => {
justify-content: center;
align-items: center;
height: 24px;
background-color: var(--ti-lowcode-base-bg-5);
background-color: var(--te-common-bg-container);
color: var(--te-common-text-weaken);

&:hover {
background-color: var(--ti-lowcode-base-gray-101);
betterdancing marked this conversation as resolved.
Show resolved Hide resolved
border-radius: 4px;
}
.selected-option {
span:hover {
color: var(--te-common-text-primary);
}
}
&.selected {
background-color: var(--ti-lowcode-base-gray-101);
color: var(--te-common-text-primary);
Expand All @@ -258,12 +267,6 @@ const change = (item) => {
display: flex;
justify-content: center;
}

&:hover {
background-color: var(--ti-lowcode-base-gray-101);
border-radius: 4px;
color: var(--te-common-text-primary);
}
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -567,6 +567,7 @@ export default {

span {
font-weight: 600;
color: var(--te-common-text-primary);
}

.svg-icon {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -327,7 +327,7 @@ onMounted(() => {
justify-content: center;
height: 24px;
border-radius: 4px;
color: var(--te-common-bg-prompt);
color: var(--te-common-text-primary);
border-width: 1px;
border-style: solid;
align-self: center;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ export default {
},
suffix: {
type: String,
default: 'PX'
default: 'px'
}
},
emits: useEvent(),
Expand Down
83 changes: 54 additions & 29 deletions packages/toolbars/media/src/Main.vue
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,20 @@
>
<tiny-popover
trigger="hover"
width="225"
width="260"
append-to-body
:open-delay="1000"
popper-class="media-icon-popover"
>
<div class="media-content">
<div class="media-title">
<div>{{ item.title }}</div>
<div v-if="item.subTitle" class="sub-title">
(<svg-icon v-if="item.view === 'desktop'" name="stars"></svg-icon> <span>{{ item.subTitle }}</span
>)
<div>
{{ item.title }}
<span v-if="item.subTitle" class="sub-title">
(<svg-icon v-if="item.view === 'desktop'" name="stars"></svg-icon>
<span>{{ item.subTitle }}</span
>)
</span>
</div>
</div>
<div class="content">{{ item.content }}</div>
Expand All @@ -32,20 +35,15 @@
</tiny-popover>
</span>
</div>
<tiny-popover v-if="isCanvas" width="290" trigger="click" popper-class="toolbar-media-popper">
<tiny-popover v-if="isCanvas" width="200" trigger="click" popper-class="toolbar-media-popper">
<template #reference>
<tiny-popover
trigger="hover"
:open-delay="1000"
popper-class="toolbar-right-popover"
append-to-body
content="画布设置"
>
<tiny-popover trigger="hover" :open-delay="1000" popper-class="toolbar-right-popover" append-to-body>
betterdancing marked this conversation as resolved.
Show resolved Hide resolved
<div class="setting-content">{{ '画布设置' }}</div>
<template #reference>
<span class="reference-text">
<span>
<span>{{ parseInt(state.width) }}</span>
<span class="symbol">PX</span>
<span class="symbol">px</span>
</span>
<span>
<span>{{ scale.toFixed(2) }}</span>
Expand All @@ -56,13 +54,13 @@
</tiny-popover>
</template>
<div class="content-wrap text-content">
<span class="title text-title">{{ state.textData.title }}</span>
<div class="title text-title">{{ state.textData.title }}</div>
<div class="setting">
<div>
<label for="">{{ state.textData.width }}</label>
<tiny-input v-model="state.width" @change="widthChange">
<template #suffix>
<span>PX</span>
<span>px</span>
</template>
</tiny-input>
</div>
Expand All @@ -74,18 +72,11 @@
</template>
</tiny-input>
</div>
<div>
<label for="">{{ '自由布局' }}</label>
betterdancing marked this conversation as resolved.
Show resolved Hide resolved
<tiny-switch v-model="isAbsolute" @change="changeCanvasType"></tiny-switch>
</div>
</div>

<ul class="more-setting">
<li>
<div>
<span>{{ '自由布局' }}</span>
</div>
<div>
<tiny-switch v-model="isAbsolute" @change="changeCanvasType"></tiny-switch>
</div>
</li>
</ul>
</div>
</tiny-popover>
</div>
Expand Down Expand Up @@ -456,7 +447,6 @@ export default {
flex-wrap: nowrap;
align-items: center;
gap: 6px;

.icon {
width: 24px;
height: 24px;
Expand Down Expand Up @@ -485,7 +475,6 @@ export default {
}
}
}

.more-setting {
.setting-item {
display: flex;
Expand All @@ -494,4 +483,40 @@ export default {
}
}
}
.media-content {
padding: 12px 8px;
line-height: 18px;
.media-title {
font-weight: 600;
}
}
.setting-content {
padding: 12px 8px;
}

.content-wrap {
padding: 20px 12px;
.title {
font-weight: 600;
margin-bottom: 16px;
}

.setting {
display: flex;
flex-direction: column;
gap: 12px;
div {
display: flex;
align-items: center;
justify-content: space-between;
label {
color: var(--te-common-text-secondary);
min-width: 64px;
}
&:last-child {
justify-content: flex-start;
}
}
}
}
</style>
Loading