sat-earth 0.8.0 → 0.8.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.
Files changed (2) hide show
  1. package/README.md +15 -8
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -5,7 +5,6 @@
5
5
  - 内置丰富基础功能组件以及菜单组件,如果不需要定制化开发,可以分分钟出一个平台级应用系统
6
6
  - 对外暴露API,可随意调用sat-earth、mars3d、cesium API 进行定制化开发
7
7
  - 功能组件可配合菜单组件也可独立运行,兼顾灵活与便捷
8
- - 对样式进行了友好的移动端适配,兼顾大屏与小屏视觉体验
9
8
  - ...
10
9
 
11
10
  ## 当前开发进度
@@ -79,7 +78,11 @@ npm i sat-earth
79
78
  ```ts
80
79
  // const piniaStore = createPinia()
81
80
  // export { piniaStore }
82
- export { piniaStore } from 'sat-earth'
81
+ import { SatStore } from 'sat-earth'
82
+ const piniaStore = SatStore.piniaStore
83
+ export {
84
+ piniaStore
85
+ }
83
86
  ```
84
87
 
85
88
  - 在 `main.[jt]s` 中引入我们的 `sat-earth` 资源
@@ -90,7 +93,11 @@ import App from "./app.vue"
90
93
  import satEarth from 'sat-earth'
91
94
  import 'sat-earth/dist/style.css'
92
95
  const app = createApp(App)
93
-
96
+ // satEarth内部引入了ElementPlus,这里可以不再引入
97
+ // import ElementPlus from 'element-plus'
98
+ // import 'element-plus/dist/index.css'
99
+ // import 'element-plus/theme-chalk/dark/css-vars.css'
100
+ // app.use(ElementPlus)
94
101
  app.use(satEarth)
95
102
  app.mount("#app")
96
103
 
@@ -140,7 +147,7 @@ app.mount("#app")
140
147
  ## 快速开始
141
148
  ```ts
142
149
  <script setup lang="ts">
143
- import { satMapTypes, type SatMenu_Type_MenuItem } from 'sat-earth'
150
+ import { SatUtil, SatCompTypes } from 'sat-earth'
144
151
  /*
145
152
  初始化参数尽量保证了和mars3d的Map构造一致性,但是任然有一些地方进行了小改动,具体查看类型SatMapOptions,下面请看改动:
146
153
  1. 在mars3d的Map构造参数的基础上扩展了custom对象。
@@ -186,7 +193,7 @@ import { satMapTypes, type SatMenu_Type_MenuItem } from 'sat-earth'
186
193
 
187
194
 
188
195
  */
189
- const options: satMapTypes.SatMapOptions = {
196
+ const options: SatUtil.types.SatMapOptions = {
190
197
  map3d: {
191
198
  control: {
192
199
  baseLayerPicker: true,
@@ -245,7 +252,7 @@ const options: satMapTypes.SatMapOptions = {
245
252
 
246
253
  const isSourceVisible = ref(true)
247
254
 
248
- const treeData = ref<SatMenu_Type_MenuItem[]>([
255
+ const treeData = ref<SatCompTypes.SatMenuItem[]>([
249
256
  {
250
257
  name: 'hello',
251
258
  label: '你好',
@@ -256,12 +263,12 @@ const treeData = ref<SatMenu_Type_MenuItem[]>([
256
263
  active: false
257
264
  },
258
265
  ])
259
- const changeDataToEnable = (item: SatMenu_Type_MenuItem) => {
266
+ const changeDataToEnable = (item: SatCompTypes.SatMenuItem) => {
260
267
  item.enable = true
261
268
  item.active = true
262
269
  console.log('do init...')
263
270
  }
264
- const changeDataToUnEnable = (item: SatMenu_Type_MenuItem) => {
271
+ const changeDataToUnEnable = (item: SatCompTypes.SatMenuItem) => {
265
272
  item.enable = false
266
273
  item.active = false
267
274
  console.log('do destroy...')
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sat-earth",
3
- "version": "0.8.0",
3
+ "version": "0.8.1",
4
4
  "private": false,
5
5
  "description": "The sat-earth is a digital earth component library based on vite3.",
6
6
  "main": "dist/sat-earth.umd.js",