@univerjs/ui 0.25.0 → 1.0.0-alpha.0

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 (85) hide show
  1. package/lib/cjs/facade.js +6 -6
  2. package/lib/cjs/index.js +4546 -3688
  3. package/lib/es/facade.js +6 -6
  4. package/lib/es/index.js +5820 -4942
  5. package/lib/facade.js +6 -6
  6. package/lib/index.css +172 -46
  7. package/lib/index.js +5820 -4942
  8. package/lib/types/common/component-manager.d.ts +3 -4
  9. package/lib/types/common/icon-manager.d.ts +86 -0
  10. package/lib/types/common/index.d.ts +1 -0
  11. package/lib/types/controllers/components.controller.d.ts +24 -0
  12. package/lib/types/controllers/menus/menus.d.ts +3 -2
  13. package/lib/types/controllers/shortcut-display/menu.d.ts +2 -1
  14. package/lib/types/controllers/shortcut-display/shortcut-panel.controller.d.ts +2 -3
  15. package/lib/types/controllers/ui/ui-desktop.controller.d.ts +0 -1
  16. package/lib/types/controllers/ui/ui-mobile.controller.d.ts +0 -1
  17. package/lib/types/index.d.ts +41 -29
  18. package/lib/types/locale/types.d.ts +18 -0
  19. package/lib/types/services/menu/menu-manager.service.d.ts +8 -0
  20. package/lib/types/services/menu/menu.d.ts +25 -31
  21. package/lib/types/services/notification/desktop-notification.service.d.ts +1 -1
  22. package/lib/types/services/notification/notification.service.d.ts +1 -1
  23. package/lib/types/services/shortcut/keycode.d.ts +2 -0
  24. package/lib/types/utils/storage-driver.d.ts +26 -0
  25. package/lib/types/{components/common-label/index.d.ts → views/CommonLabel.d.ts} +1 -1
  26. package/lib/types/{components/heading-item/index.d.ts → views/HeadingItem.d.ts} +1 -1
  27. package/lib/types/views/components/confirm-part/ConfirmPart.d.ts +1 -1
  28. package/lib/types/views/components/confirm-part/interface.d.ts +1 -1
  29. package/lib/types/views/components/context-menu/AnchoredContextMenu.d.ts +1 -1
  30. package/lib/types/views/components/context-menu/ContextMenu.d.ts +1 -1
  31. package/lib/types/views/components/context-menu/ContextMenuPanel.d.ts +19 -1
  32. package/lib/types/views/components/dialog-part/DialogPart.d.ts +1 -1
  33. package/lib/types/views/components/dialog-part/interface.d.ts +1 -1
  34. package/lib/types/views/components/dom/FloatDom.d.ts +2 -2
  35. package/lib/types/views/components/dom/Print.d.ts +1 -1
  36. package/lib/types/views/components/gallery-part/GalleryPart.d.ts +1 -1
  37. package/lib/types/views/components/popup/CanvasPopup.d.ts +2 -2
  38. package/lib/types/views/components/popup/RectPopup.d.ts +1 -1
  39. package/lib/types/views/components/ribbon/MobileRibbon.d.ts +1 -1
  40. package/lib/types/views/components/ribbon/Ribbon.d.ts +1 -1
  41. package/lib/types/views/components/ribbon/ToolbarButton.d.ts +5 -1
  42. package/lib/types/views/components/ribbon/TooltipButtonWrapper.d.ts +9 -3
  43. package/lib/types/views/components/ribbon/hook.d.ts +1 -0
  44. package/lib/types/views/components/ribbon/ribbon-menu/ClassicMenu.d.ts +1 -1
  45. package/lib/types/views/components/ribbon/ribbon-menu/DefaultMenu.d.ts +1 -1
  46. package/lib/types/views/components/shortcut-panel/ShortcutPanel.d.ts +1 -1
  47. package/lib/types/views/components/sidebar/Sidebar.d.ts +2 -2
  48. package/lib/types/{components → views}/custom-label/CustomLabel.d.ts +2 -2
  49. package/lib/types/{components → views}/font-family/FontFamily.d.ts +1 -1
  50. package/lib/types/{components → views}/font-family/FontFamilyItem.d.ts +1 -1
  51. package/lib/types/{components → views}/font-size/FontSize.d.ts +1 -1
  52. package/lib/types/{components → views}/hooks/layout.d.ts +1 -1
  53. package/lib/types/{components → views}/index.d.ts +4 -4
  54. package/lib/types/{components → views}/menu/desktop/DesignTinyMenuGroup.d.ts +11 -7
  55. package/lib/types/{components → views}/menu/desktop/TinyMenuGroup.d.ts +7 -2
  56. package/lib/types/{components → views}/menu/mobile/MobileMenu.d.ts +1 -1
  57. package/lib/types/{components → views}/menu/mobile/MobileMenu.stories.d.ts +1 -1
  58. package/lib/types/views/{components/zen-zone/ZenZone.d.ts → message/MessageContainer.d.ts} +1 -1
  59. package/lib/types/views/mobile-workbench/MobileWorkbench.d.ts +3 -1
  60. package/lib/types/{components → views}/notification/Notification.d.ts +1 -1
  61. package/lib/types/{components → views}/notification/Notification.stories.d.ts +5 -5
  62. package/lib/types/{components → views}/progress-bar/ProgressBar.d.ts +1 -1
  63. package/lib/types/{components → views}/slider/Slider.d.ts +1 -1
  64. package/lib/types/{components → views}/slider/Slider.stories.d.ts +1 -1
  65. package/lib/types/views/workbench/Workbench.d.ts +4 -2
  66. package/lib/umd/index.js +25 -131
  67. package/package.json +9 -10
  68. package/lib/types/components/message/MessageContainer.d.ts +0 -16
  69. package/lib/types/services/zen-zone/desktop-zen-zone.service.d.ts +0 -37
  70. package/lib/types/services/zen-zone/zen-zone.service.d.ts +0 -37
  71. /package/lib/types/services/message/{__testing__ → __tests__}/mock-message.service.d.ts +0 -0
  72. /package/lib/types/{components → views}/color-picker/interface.d.ts +0 -0
  73. /package/lib/types/{components → views}/custom-label/index.d.ts +0 -0
  74. /package/lib/types/{components → views}/font-family/index.d.ts +0 -0
  75. /package/lib/types/{components → views}/font-family/interface.d.ts +0 -0
  76. /package/lib/types/{components → views}/font-size/interface.d.ts +0 -0
  77. /package/lib/types/{components → views}/hooks/event.d.ts +0 -0
  78. /package/lib/types/{components → views}/hooks/index.d.ts +0 -0
  79. /package/lib/types/{components → views}/hooks/update-effect.d.ts +0 -0
  80. /package/lib/types/{components → views}/hooks/use-click-out-side.d.ts +0 -0
  81. /package/lib/types/{components → views}/hooks/use-debounce.d.ts +0 -0
  82. /package/lib/types/{components → views}/hooks/virtual-list.d.ts +0 -0
  83. /package/lib/types/{components → views}/menu/common/hook.d.ts +0 -0
  84. /package/lib/types/{components → views}/menu/types.d.ts +0 -0
  85. /package/lib/types/{components → views}/slider/index.d.ts +0 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@univerjs/ui",
3
- "version": "0.25.0",
3
+ "version": "1.0.0-alpha.0",
4
4
  "private": false,
5
5
  "description": "Shared application UI framework, workbench services, menus, dialogs, and Facade UI APIs for Univer.",
6
6
  "author": "DreamNum Co., Ltd. <developer@univer.ai>",
@@ -69,12 +69,11 @@
69
69
  "rxjs": ">=7.0.0"
70
70
  },
71
71
  "dependencies": {
72
- "@univerjs/icons": "1.4.0",
73
- "@wendellhu/redi": "1.1.1",
74
- "localforage": "^1.10.0",
75
- "@univerjs/design": "0.25.0",
76
- "@univerjs/engine-render": "0.25.0",
77
- "@univerjs/core": "0.25.0"
72
+ "@univerjs/icons": "1.12.0",
73
+ "@wendellhu/redi": "1.1.2",
74
+ "@univerjs/core": "1.0.0-alpha.0",
75
+ "@univerjs/engine-render": "1.0.0-alpha.0",
76
+ "@univerjs/design": "1.0.0-alpha.0"
78
77
  },
79
78
  "devDependencies": {
80
79
  "@testing-library/react": "^16.3.2",
@@ -85,9 +84,9 @@
85
84
  "tailwindcss": "3.4.18",
86
85
  "tailwindcss-animate": "^1.0.7",
87
86
  "typescript": "^6.0.3",
88
- "vitest": "^4.1.7",
89
- "@univerjs-infra/shared": "0.25.0",
90
- "@univerjs/themes": "0.25.0"
87
+ "vitest": "^4.1.9",
88
+ "@univerjs/themes": "1.0.0-alpha.0",
89
+ "@univerjs-infra/shared": "1.0.0-alpha.0"
91
90
  },
92
91
  "scripts": {
93
92
  "test": "vitest run",
@@ -1,16 +0,0 @@
1
- /**
2
- * Copyright 2023-present DreamNum Co., Ltd.
3
- *
4
- * Licensed under the Apache License, Version 2.0 (the "License");
5
- * you may not use this file except in compliance with the License.
6
- * You may obtain a copy of the License at
7
- *
8
- * http://www.apache.org/licenses/LICENSE-2.0
9
- *
10
- * Unless required by applicable law or agreed to in writing, software
11
- * distributed under the License is distributed on an "AS IS" BASIS,
12
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
- * See the License for the specific language governing permissions and
14
- * limitations under the License.
15
- */
16
- export declare function MessageContainer(): import("react/jsx-runtime").JSX.Element;
@@ -1,37 +0,0 @@
1
- /**
2
- * Copyright 2023-present DreamNum Co., Ltd.
3
- *
4
- * Licensed under the Apache License, Version 2.0 (the "License");
5
- * you may not use this file except in compliance with the License.
6
- * You may obtain a copy of the License at
7
- *
8
- * http://www.apache.org/licenses/LICENSE-2.0
9
- *
10
- * Unless required by applicable law or agreed to in writing, software
11
- * distributed under the License is distributed on an "AS IS" BASIS,
12
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
- * See the License for the specific language governing permissions and
14
- * limitations under the License.
15
- */
16
- import type { IDisposable } from '@univerjs/core';
17
- import type { ComponentType } from '../../common/component-manager';
18
- import type { IZenZoneService } from './zen-zone.service';
19
- import { BehaviorSubject, ReplaySubject } from 'rxjs';
20
- import { ComponentManager } from '../../common/component-manager';
21
- export declare class DesktopZenZoneService implements IZenZoneService, IDisposable {
22
- private readonly _componentManager;
23
- readonly visible$: BehaviorSubject<boolean>;
24
- readonly componentKey$: ReplaySubject<string>;
25
- private readonly _temporaryHidden$;
26
- readonly temporaryHidden$: import("rxjs").Observable<boolean>;
27
- private _visible;
28
- get visible(): boolean;
29
- get temporaryHidden(): boolean;
30
- constructor(_componentManager: ComponentManager);
31
- dispose(): void;
32
- hide(): void;
33
- show(): void;
34
- set(key: string, component: ComponentType): IDisposable;
35
- open(): void;
36
- close(): void;
37
- }
@@ -1,37 +0,0 @@
1
- /**
2
- * Copyright 2023-present DreamNum Co., Ltd.
3
- *
4
- * Licensed under the Apache License, Version 2.0 (the "License");
5
- * you may not use this file except in compliance with the License.
6
- * You may obtain a copy of the License at
7
- *
8
- * http://www.apache.org/licenses/LICENSE-2.0
9
- *
10
- * Unless required by applicable law or agreed to in writing, software
11
- * distributed under the License is distributed on an "AS IS" BASIS,
12
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
- * See the License for the specific language governing permissions and
14
- * limitations under the License.
15
- */
16
- import type { IDisposable } from '@univerjs/core';
17
- import type { BehaviorSubject, Observable, ReplaySubject } from 'rxjs';
18
- import type { ComponentType } from '../../common/component-manager';
19
- export declare const IZenZoneService: import("@wendellhu/redi").IdentifierDecorator<IZenZoneService>;
20
- export interface IZenZoneService {
21
- readonly visible$: BehaviorSubject<boolean>;
22
- readonly componentKey$: ReplaySubject<string>;
23
- readonly temporaryHidden$: Observable<boolean>;
24
- readonly visible: boolean;
25
- readonly temporaryHidden: boolean;
26
- set(key: string, component: ComponentType): IDisposable;
27
- open(): void;
28
- close(): void;
29
- /**
30
- * temporarily hide the zen zone, often
31
- */
32
- hide(): void;
33
- /**
34
- * show the zen zone
35
- */
36
- show(): void;
37
- }
File without changes