@techui/scifi 0.0.7-alpha.7 → 0.1.0-alpha.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.js CHANGED
@@ -1,5 +1,6 @@
1
- import "@techui/icons";
1
+ import "@techui/icons";
2
2
  import "./dist/index.css";
3
+ import { tCryptoStore, tLang } from "@techui/utils";
3
4
  import { toComps, toDirective, toGlobal, toRoot } from "./dist/index.js";
4
5
 
5
6
  const aliasName={
@@ -50,7 +51,7 @@ const advanceComps=[
50
51
  "TuiBar3D",
51
52
  "TuiBar3DGroup",
52
53
  "TuiPie",
53
- "TuiToggleT3DPanel",
54
+ "TuiT3DPanelToggle",
54
55
  "TuiPanicAlert",
55
56
  ]
56
57
 
@@ -59,7 +60,7 @@ const echartsComps=[
59
60
  "TuiEchartsMap",
60
61
  ]
61
62
 
62
- const initComps=(app,license,features,debug=false)=>{
63
+ const initComps=(app,license,features,debug=false,initLang=null)=>{
63
64
  const {echarts=null,advanced=false}=features
64
65
  const isActEcharts = (
65
66
  echarts !== null &&
@@ -77,7 +78,7 @@ const initComps=(app,license,features,debug=false)=>{
77
78
  app.directive('tuiPopover', toDirective.$dPopover)
78
79
  app.directive('tuiCursorTip', toDirective.$dCursorTip)
79
80
  app.directive('tuiVcid', toDirective.$dVcid)
80
- const tService=toRoot.tuiService(advanced,debug)
81
+ const tService=toRoot.tuiService(advanced,debug,initLang)
81
82
  app.config.globalProperties.$tBus = toRoot.tuiBus
82
83
  app.config.globalProperties.$tService = tService
83
84
  app.config.globalProperties.$tState = tService.state
@@ -105,116 +106,127 @@ const initComps=(app,license,features,debug=false)=>{
105
106
  });
106
107
  };
107
108
 
108
- import { initLang } from "@techui/utils";
109
-
110
109
  import init, {
111
- coreInfo,
112
- techuiCoreInit
110
+ coreInfo,
111
+ openDec,
112
+ setLang,
113
+ techuiCoreInit
113
114
  } from './core/core.js';
114
115
 
115
116
  export {
116
- adptCalc, bar3DPathGen, cidGen, cidVaild, coreConsoleError, coreConsoleInfo, coreConsoleWarn, cssVarGen, floatInfo, getEnv, getVer,
117
- md5Enc, openDec, openEnc, pieArcPathGen,
118
-
119
- //button
120
- scifiButtonA1, scifiButtonA2, scifiButtonA3, scifiButtonA4, scifiButtonA5,
121
-
122
- //deco
123
- scifiDecoA1, scifiDecoB1, scifiDecoB2, scifiDecoB3, scifiDecoD1,
124
-
125
- //geometry
126
- scifiGeomeParallelogram, scifiGeomeRectangle, scifiGeomeTrapezoid, scifiGeomeTriangle, scifiGeomHexagon,
127
-
128
- //header
129
- scifiHeaderA1, scifiHeaderA2, scifiHeaderA3, scifiHeaderA4,
130
-
131
- //panel
132
- scifiPanelA1, scifiPanelA2, scifiPanelA3,
133
- scifiPanelB1, scifiPanelB2, scifiPanelB3, scifiPanelB4,
134
- scifiPanelDV1, scifiPanelDV2, scifiPanelDV3, scifiPanelDV4, scifiPanelDV5,
135
- scifiPanelDV6, scifiPanelDV7, scifiPanelDV8, scifiPanelDV9,
136
-
137
- //panel title
138
- scifiPanelTitleA1, scifiPanelTitleA2, scifiPanelTitleA3,
139
-
140
- svgPatBlocks,
141
- svgPatCircuitDiagram,
142
- svgPatCircularOverlayA,
143
- svgPatCircularOverlayB,
144
- svgPatContourLine,
145
- svgPatCrosshairA,
146
- svgPatCrosshairB,
147
- svgPatCubeA,
148
- svgPatCubeB,
149
- svgPatCubeC,
150
- svgPatDiamondFlipped,
151
- svgPatDiamondLattice,
152
- svgPatDiamondPixel,
153
- svgPatDiamondWeaving,
154
- svgPatDots,
155
- svgPatHexagonA,
156
- svgPatHexagonB,
157
- svgPatHexagonC,
158
- svgPatHexagonCurved,
159
- svgPatHexagonD,
160
- svgPatLineGrid,
161
- svgPatLineWeaving,
162
- svgPatMazeA,
163
- svgPatMazeB,
164
- svgPatMazeC,
165
- svgPatMountains,
166
- svgPatRain,
167
- svgPatRectWeavingA,
168
- svgPatRectWeavingB,
169
- svgPatRectWeavingC,
170
- svgPatShellA,
171
- svgPatShellB,
172
- svgPatSlashParallel,
173
- svgPatTest,
174
- svgPatTotem,
175
- svgPatTriangleA,
176
- svgPatTriangleB,
177
- svgPatWaveA,
178
- svgPatWaveB,
179
- svgPatZigzagA,
180
- svgPatZigzagB,
181
-
182
- svgSpinBarsA,
183
- svgSpinBarsB,
184
- svgSpinBarsC,
185
- svgSpinBlocksA,
186
- svgSpinBlocksB,
187
- svgSpinBlocksC,
188
- svgSpinClock,
189
- svgSpinPointA,
190
- svgSpinPointB,
191
- svgSpinPointC,
192
- svgSpinPulseDotA,
193
- svgSpinPulseDotB,
194
- svgSpinPulseDotC,
195
- svgSpinPulseRingA,
196
- svgSpinPulseRingB,
197
- svgSpinPulseRingC,
198
- svgSpinRingA,
199
- svgSpinRingB,
200
- svgSpinRingC,
201
-
202
- t3dCoeffCalc,
203
- t3dUpdateOrient,
204
- t3dUpdateRotate
117
+ adptCalc, bar3DPathGen, cidGen, cidVaild, coreConsoleError, coreConsoleInfo, coreConsoleWarn, cssVarGen, floatInfo, getEnv, getVer,
118
+ md5Enc, openDec, openEnc, pieArcPathGen, setLang,
119
+
120
+ //button
121
+ scifiButtonA1, scifiButtonA2, scifiButtonA3, scifiButtonA4, scifiButtonA5,
122
+
123
+ //deco
124
+ scifiDecoA1, scifiDecoB1, scifiDecoB2, scifiDecoB3, scifiDecoD1,
125
+
126
+ //geometry
127
+ scifiGeomeParallelogram, scifiGeomeRectangle, scifiGeomeTrapezoid, scifiGeomeTriangle, scifiGeomHexagon,
128
+
129
+ //header
130
+ scifiHeaderA1, scifiHeaderA2, scifiHeaderA3, scifiHeaderA4,
131
+
132
+ //panel
133
+ scifiPanelA1, scifiPanelA2, scifiPanelA3,
134
+ scifiPanelB1, scifiPanelB2, scifiPanelB3, scifiPanelB4,
135
+ scifiPanelDV1, scifiPanelDV2, scifiPanelDV3, scifiPanelDV4, scifiPanelDV5,
136
+ scifiPanelDV6, scifiPanelDV7, scifiPanelDV8, scifiPanelDV9,
137
+
138
+ //panel title
139
+ scifiPanelTitleA1, scifiPanelTitleA2, scifiPanelTitleA3,
140
+
141
+ svgPatBlocks,
142
+ svgPatCircuitDiagram,
143
+ svgPatCircularOverlayA,
144
+ svgPatCircularOverlayB,
145
+ svgPatContourLine,
146
+ svgPatCrosshairA,
147
+ svgPatCrosshairB,
148
+ svgPatCubeA,
149
+ svgPatCubeB,
150
+ svgPatCubeC,
151
+ svgPatDiamondFlipped,
152
+ svgPatDiamondLattice,
153
+ svgPatDiamondPixel,
154
+ svgPatDiamondWeaving,
155
+ svgPatDots,
156
+ svgPatHexagonA,
157
+ svgPatHexagonB,
158
+ svgPatHexagonC,
159
+ svgPatHexagonCurved,
160
+ svgPatHexagonD,
161
+ svgPatLineGrid,
162
+ svgPatLineWeaving,
163
+ svgPatMazeA,
164
+ svgPatMazeB,
165
+ svgPatMazeC,
166
+ svgPatMountains,
167
+ svgPatRain,
168
+ svgPatRectWeavingA,
169
+ svgPatRectWeavingB,
170
+ svgPatRectWeavingC,
171
+ svgPatShellA,
172
+ svgPatShellB,
173
+ svgPatSlashParallel,
174
+ svgPatTest,
175
+ svgPatTotem,
176
+ svgPatTriangleA,
177
+ svgPatTriangleB,
178
+ svgPatWaveA,
179
+ svgPatWaveB,
180
+ svgPatZigzagA,
181
+ svgPatZigzagB,
182
+
183
+ svgSpinBarsA,
184
+ svgSpinBarsB,
185
+ svgSpinBarsC,
186
+ svgSpinBlocksA,
187
+ svgSpinBlocksB,
188
+ svgSpinBlocksC,
189
+ svgSpinClock,
190
+ svgSpinPointA,
191
+ svgSpinPointB,
192
+ svgSpinPointC,
193
+ svgSpinPulseDotA,
194
+ svgSpinPulseDotB,
195
+ svgSpinPulseDotC,
196
+ svgSpinPulseRingA,
197
+ svgSpinPulseRingB,
198
+ svgSpinPulseRingC,
199
+ svgSpinRingA,
200
+ svgSpinRingB,
201
+ svgSpinRingC,
202
+
203
+ t3dCoeffCalc,
204
+ t3dUpdateOrient,
205
+ t3dUpdateRotate
205
206
  } from './core/core.js';
206
207
 
208
+ const getBootLang = (initLang = null) => {
209
+ const storedLocale = tCryptoStore.g("local", "globalConfig", openDec)?.lang
210
+ if (["zh-CN", "zh-TW", "en"].includes(storedLocale)) {
211
+ return storedLocale
212
+ }
213
+ if (["zh-CN", "zh-TW", "en"].includes(initLang)) {
214
+ return initLang
215
+ }
216
+ return tLang.getSysLang() || "zh-CN"
217
+ }
207
218
  const coreEnt=async ({
208
219
  app,
209
220
  license=null,
221
+ initLang=null,
210
222
  subLicense=null,
211
223
  features={},
212
224
  debug=false
213
225
  })=>{
214
- initLang();
215
226
  await init();
227
+ setLang(getBootLang(initLang))
216
228
  window.tuiCoreInfo=coreInfo
217
229
  techuiCoreInit(license,subLicense,coreEnt.toString());
218
- app.use(initComps,license,features,debug)
230
+ app.use(initComps,license,features,debug,initLang)
219
231
  };
220
- export default coreEnt
232
+ export default coreEnt
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@techui/scifi",
3
- "version": "0.0.7-alpha.7",
3
+ "version": "0.1.0-alpha.1",
4
4
  "description": "TechUI Scifi is a sci-fi SVG component library developed based on Vue3. It uses dynamically calculated SVG elements to generate a variety of cool, futuristic, and technological components.",
5
5
  "author": "aYin <ayin86cn@gmail.com> <wechat:jay1986cn>",
6
6
  "homepage": "https://techui.net",
@@ -41,15 +41,15 @@
41
41
  ],
42
42
 
43
43
  "dependencies": {
44
- "@techui/icons": "1.0.3",
44
+ "@techui/icons": "1.0.4",
45
45
  "@techui/colors": "1.0.2",
46
46
  "@techui/lessmixins": "0.0.6",
47
47
  "@techui/libs": "0.0.6",
48
- "@techui/locales": "0.0.7",
49
- "@techui/themes": "0.0.7",
50
- "@techui/utils": "0.0.7",
48
+ "@techui/locales": "0.1.0",
49
+ "@techui/themes": "0.1.0",
50
+ "@techui/utils": "0.1.0",
51
51
  "vue": "^3.4.27",
52
- "vue-router": "^4.3.2"
52
+ "vue-router": "^4.6.4"
53
53
  },
54
54
  "publishConfig": {
55
55
  "access": "public"