Skip to content

Commit

Permalink
Merge branch 'refactor/develop' of https://github.com/betterdancing/t…
Browse files Browse the repository at this point in the history
…iny-engine into refactor/style-panel
  • Loading branch information
betterdancing committed Oct 31, 2024
2 parents aa8e61f + d283c5a commit a964715
Show file tree
Hide file tree
Showing 81 changed files with 284 additions and 120 deletions.
2 changes: 1 addition & 1 deletion designer-demo/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "designer-demo",
"private": true,
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"type": "module",
"scripts": {
"dev": "cross-env VITE_THEME=light vite",
Expand Down
2 changes: 1 addition & 1 deletion mockServer/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentiny/tiny-engine-mock",
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"publishConfig": {
"access": "public"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/blockToWebComponentTemplate/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentiny/tiny-engine-block-build",
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"description": "translate block to webcomponent template",
"main": "./dist/web-components.es.js",
"type": "module",
Expand Down
2 changes: 1 addition & 1 deletion packages/build/vite-config/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentiny/tiny-engine-vite-config",
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"description": "",
"type": "module",
"main": "./index.js",
Expand Down
2 changes: 1 addition & 1 deletion packages/build/vite-plugin-meta-comments/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentiny/tiny-engine-vite-plugin-meta-comments",
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"description": "",
"type": "module",
"main": "dist/index.cjs",
Expand Down
2 changes: 1 addition & 1 deletion packages/builtinComponent/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentiny/tiny-engine-builtin-component",
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"description": "",
"main": "dist/index.js",
"module": "dist/index.js",
Expand Down
2 changes: 1 addition & 1 deletion packages/canvas/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentiny/tiny-engine-canvas",
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"publishConfig": {
"access": "public"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/common/component/ConfigItem.vue
Original file line number Diff line number Diff line change
Expand Up @@ -518,7 +518,7 @@ export default {
justify-content: space-between;
position: relative;
align-items: center;
padding-bottom: 8px;
padding-bottom: var(--te-common-vertical-item-spacing-normal);
&:last-child {
padding-bottom: 0;
}
Expand Down
6 changes: 5 additions & 1 deletion packages/common/component/MetaChildItem.vue
Original file line number Diff line number Diff line change
Expand Up @@ -93,15 +93,19 @@ export default {
color: var(--te-common-text-primary);
padding: 0 10px;
font-weight: bold;
margin-bottom: 16px;
}
.items-container {
width: 100%;
display: flex;
flex-wrap: wrap;
flex-direction: column;
height: calc(100% - 34px); // 34为头部+底部的高度
overflow-y: auto;
.meta-config-item {
flex: 1;
padding: 0 10px;
margin-bottom: var(--te-common-vertical-item-spacing-normal);
}
}
</style>
15 changes: 15 additions & 0 deletions packages/common/component/MetaCodeEditor.vue
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@
</div>
<tiny-button v-else class="edit-btn" @click="open">
<slot name="icon"></slot>
<svg-icon
name="page-schema"
v-if="[buttonText[locale], buttonText].includes(EDIT_CODE_TEXT)"
class="edit-btn-icon"
></svg-icon>

{{ buttonLabel }}
</tiny-button>
</slot>
Expand Down Expand Up @@ -143,6 +149,8 @@ export default {
const editorTipsTitle = computed(() => props.tips?.title?.[locale.value] ?? props.tips?.title)
const editorTipsDemo = computed(() => props.tips?.demo?.[locale.value] ?? props.tips?.demo)
const EDIT_CODE_TEXT = '编辑代码'
watchEffect(() => {
const { modelValue, dataType } = props
const val = dataType ? modelValue?.value || '' : modelValue
Expand Down Expand Up @@ -239,6 +247,7 @@ export default {
editor,
editorState,
value,
EDIT_CODE_TEXT,
options: {
language: props.language,
minimap: {
Expand Down Expand Up @@ -267,6 +276,12 @@ export default {
&:focus {
border-color: var(--te-common-border-active);
}
.edit-btn-icon {
font-size: 14px;
margin-right: 4px;
vertical-align: text-top;
color: var(--te-common-icon-secondary);
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion packages/common/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentiny/tiny-engine-common",
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"publishConfig": {
"access": "public"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/configurator/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentiny/tiny-engine-configurator",
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"description": "",
"main": "dist/index.js",
"module": "dist/index.js",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,19 @@
<div class="label">使用插槽</div>
<tiny-form ref="slotRef" class="slot-form" :model="slotList" label-width="0" inline>
<div v-for="(slot, index) in slotList" :key="slot.name" class="use-slot">
<div class="use-slot-item-name">{{ slot.name }}</div>
<div class="use-slot-item-name">
{{ slot.name }}
<tiny-tooltip effect="dark" :content="state.currentComponent?.content" placement="top">
<span class="item-icon">
<component :is="state.currentComponent?.icon"></component>
</span>
</tiny-tooltip>
</div>
<div class="use-slot-item-content">
<div class="use-slot-switch-wrap">
<div :class="['e__switch', { 'e_is-checked': slot.bind }]">
<span class="e__switch-core" @click="toggleSlot(index, slot)"></span>
</div>
<tiny-tooltip effect="dark" :content="state.currentComponent?.content" placement="top">
<span class="item-icon">
<component :is="state.currentComponent?.icon"></component>
</span>
</tiny-tooltip>
</div>
<tiny-form-item
:prop="paramsPropPath(index)"
Expand Down Expand Up @@ -191,6 +193,7 @@ export default {
.use-slot-switch-wrap {
display: flex;
align-items: center;
}
&-item-name {
Expand All @@ -214,7 +217,7 @@ export default {
}
.item-icon {
margin: 3px 3px 0 6px;
margin: 0 3px 0 6px;
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,17 +128,17 @@ export default {
}
input[type='range'] {
height: 4px;
border-radius: 8px;
border-radius: 10px;
margin: 0.8em 0;
padding: 0;
cursor: pointer;
border: 0;
background: -webkit-linear-gradient(var(--te-base-gray-1), var(--te-base-gray-1)) no-repeat var(--te-base-gray-17);
background-size: 0% 100%;
background-color: transparent;
position: relative;
outline: 0;
top: -1px;
-webkit-appearance: none !important;
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
}
input[type='range']::-webkit-slider-thumb {
width: 10px;
Expand All @@ -152,7 +152,9 @@ export default {
cursor: pointer;
background-clip: padding-box;
box-sizing: border-box;
-webkit-appearance: none !important;
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
}
input[type='range']::-webkit-slider-thumb:active {
border: 0;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ export default {
justify-content: center;
align-items: center;
&:not(:last-child) {
margin-bottom: 8px;
margin-bottom: var(--te-common-vertical-item-spacing-normal);
}
.slot-name {
width: 30%;
Expand Down
32 changes: 17 additions & 15 deletions packages/design-core/assets/empty-action.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion packages/design-core/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentiny/tiny-engine",
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"type": "module",
"description": "TinyEngine enables developers to customize low-code platforms, build low-bit platforms online in real time, and support secondary development or integration of low-bit platform capabilities.",
"homepage": "https://opentiny.design/tiny-engine",
Expand Down
2 changes: 1 addition & 1 deletion packages/engine-cli/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentiny/tiny-engine-cli",
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"description": "",
"main": "dist/index.js",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion packages/http/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentiny/tiny-engine-http",
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"publishConfig": {
"access": "public"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/i18n/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentiny/tiny-engine-i18n-host",
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"publishConfig": {
"access": "public"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/layout/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentiny/tiny-engine-layout",
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"scripts": {
"build": "vite build"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/plugins/block/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentiny/tiny-engine-plugin-block",
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"publishConfig": {
"access": "public"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/plugins/bridge/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentiny/tiny-engine-plugin-bridge",
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"publishConfig": {
"access": "public"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/plugins/datasource/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentiny/tiny-engine-plugin-datasource",
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"publishConfig": {
"access": "public"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/plugins/help/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentiny/tiny-engine-plugin-help",
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"publishConfig": {
"access": "public"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/plugins/i18n/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentiny/tiny-engine-plugin-i18n",
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"publishConfig": {
"access": "public"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/plugins/materials/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentiny/tiny-engine-plugin-materials",
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"publishConfig": {
"access": "public"
},
Expand Down
3 changes: 1 addition & 2 deletions packages/plugins/page/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,10 @@ import entry, { api } from './src/Main.vue'
import metaData from './meta.js'
import { PageService } from './src/composable'
import PageGeneral from './src/PageGeneral.vue'
import { api as pageSettingApi } from './src/PageSetting.vue'

export default {
...metaData,
apis: { ...api, ...pageSettingApi },
apis: api,
entry,
components: {
PageGeneral
Expand Down
2 changes: 1 addition & 1 deletion packages/plugins/page/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentiny/tiny-engine-plugin-page",
"version": "2.0.0-alpha.5",
"version": "2.0.0-alpha.6",
"publishConfig": {
"access": "public"
},
Expand Down
Loading

0 comments on commit a964715

Please sign in to comment.