Skip to content

Commit a90bf6d

Browse files
committed
feat(resource-manager): add resource manager plugin
1 parent da1c7d6 commit a90bf6d

17 files changed

Lines changed: 132 additions & 4 deletions

File tree

designer-demo/public/mock/bundle.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4433,18 +4433,19 @@
44334433
"bindState": true,
44344434
"label": {
44354435
"text": {
4436-
"zh_CN": "资源"
4436+
"zh_CN": "资源选择"
44374437
}
44384438
},
44394439
"cols": 12,
44404440
"rules": [],
44414441
"widget": {
4442-
"component": "InputConfigurator",
4442+
"component": "SourceSelectConfigurator",
44434443
"props": {}
44444444
},
44454445
"description": {
44464446
"zh_CN": "src路径"
4447-
}
4447+
},
4448+
"labelPosition": "top"
44484449
},
44494450
{
44504451
"property": "attributes3",

packages/build/vite-config/src/vite-plugins/devAliasPlugin.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ const getDevAlias = (useSourceAlias) => {
2929
'@opentiny/tiny-engine-plugin-bridge': path.resolve(basePath, 'packages/plugins/bridge/index.ts'),
3030
'@opentiny/tiny-engine-plugin-tutorial': path.resolve(basePath, 'packages/plugins/tutorial/index.ts'),
3131
'@opentiny/tiny-engine-plugin-robot': path.resolve(basePath, 'packages/plugins/robot/index.ts'),
32+
'@opentiny/tiny-engine-plugin-resource': path.resolve(basePath, 'packages/plugins/resource/index.ts'),
3233
'@opentiny/tiny-engine-settings-panel': path.resolve(basePath, 'packages/settings/panel/index.ts'),
3334
'@opentiny/tiny-engine-setting-events': path.resolve(basePath, 'packages/settings/events/index.ts'),
3435
'@opentiny/tiny-engine-setting-props': path.resolve(basePath, 'packages/settings/props/index.ts'),

packages/configurator/src/source-select-configurator/SourceSelectConfigurator.vue

Whitespace-only changes.

packages/configurator/src/source-select-configurator/http.ts

Whitespace-only changes.

packages/design-core/assets/plugin-icon-resource.svg

Loading

packages/design-core/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@
5757
"@opentiny/tiny-engine-plugin-materials": "workspace:*",
5858
"@opentiny/tiny-engine-plugin-page": "workspace:*",
5959
"@opentiny/tiny-engine-plugin-robot": "workspace:*",
60+
"@opentiny/tiny-engine-plugin-resource": "workspace:*",
6061
"@opentiny/tiny-engine-plugin-schema": "workspace:*",
6162
"@opentiny/tiny-engine-plugin-script": "workspace:*",
6263
"@opentiny/tiny-engine-plugin-state": "workspace:*",

packages/design-core/re-export.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ export { default as Bridge } from '@opentiny/tiny-engine-plugin-bridge'
2727
export { default as Block, BlockService } from '@opentiny/tiny-engine-plugin-block'
2828
export { default as Datasource, DataSourceService } from '@opentiny/tiny-engine-plugin-datasource'
2929
export { default as Robot } from '@opentiny/tiny-engine-plugin-robot'
30+
export { default as Resource } from '@opentiny/tiny-engine-plugin-resource'
3031
export { default as Props, PropertiesService, PropertyService } from '@opentiny/tiny-engine-setting-props'
3132
export { default as Events } from '@opentiny/tiny-engine-setting-events'
3233
export { default as Styles } from '@opentiny/tiny-engine-setting-styles'

packages/layout/src/defaultLayout.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@ export default {
1212
META_APP.Bridge,
1313
META_APP.I18n,
1414
META_APP.Page,
15-
META_APP.State
15+
META_APP.State,
16+
META_APP.Resource
1617
],
1718
bottom: [META_APP.Schema, META_APP.Help, META_APP.Robot]
1819
},

packages/plugins/resource/index.ts

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
/**
2+
* Copyright (c) 2023 - present TinyEngine Authors.
3+
* Copyright (c) 2023 - present Huawei Cloud Computing Technologies Co., Ltd.
4+
*
5+
* Use of this source code is governed by an MIT-style license.
6+
*
7+
* THE OPEN SOURCE SOFTWARE IN THIS PRODUCT IS DISTRIBUTED IN THE HOPE THAT IT WILL BE USEFUL,
8+
* BUT WITHOUT ANY WARRANTY, WITHOUT EVEN THE IMPLIED WARRANTY OF MERCHANTABILITY OR FITNESS FOR
9+
* A PARTICULAR PURPOSE. SEE THE APPLICABLE LICENSES FOR MORE DETAILS.
10+
*
11+
*/
12+
13+
import entry from './src/Main.vue'
14+
import metaData from './meta'
15+
16+
export default {
17+
...metaData,
18+
entry
19+
}

packages/plugins/resource/meta.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
export default {
2+
id: 'engine.plugins.resource',
3+
title: '资源管理',
4+
type: 'plugins',
5+
icon: 'plugin-icon-resource'
6+
}

0 commit comments

Comments
 (0)