@univerjs/ui 0.1.0-beta.4 → 0.1.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 (27) hide show
  1. package/lib/cjs/index.js +12 -12
  2. package/lib/es/index.js +3780 -3536
  3. package/lib/index.css +1 -1
  4. package/lib/types/commands/operations/editor/set-editor-resize.operation.d.ts +17 -0
  5. package/lib/types/components/editor/TextEditor.d.ts +35 -0
  6. package/lib/types/controllers/ui/ui-desktop.controller.d.ts +3 -5
  7. package/lib/types/index.d.ts +6 -2
  8. package/lib/types/locale/en-US.d.ts +3 -47
  9. package/lib/types/locale/zh-CN.d.ts +2 -2
  10. package/lib/types/services/confirm/confirm.service.d.ts +2 -2
  11. package/lib/types/services/confirm/desktop-confirm.service.d.ts +1 -1
  12. package/lib/types/services/dialog/desktop-dialog.service.d.ts +1 -1
  13. package/lib/types/services/dialog/dialog.service.d.ts +2 -2
  14. package/lib/types/services/editor/editor.service.d.ts +147 -0
  15. package/lib/types/services/global-zone/desktop-global-zone.service.d.ts +29 -0
  16. package/lib/types/services/global-zone/global-zone.service.d.ts +25 -0
  17. package/lib/types/services/layout/layout.service.d.ts +42 -5
  18. package/lib/types/services/shortcut/shortcut.service.d.ts +4 -2
  19. package/lib/types/services/sidebar/desktop-sidebar.service.d.ts +1 -1
  20. package/lib/types/services/sidebar/sidebar.service.d.ts +1 -1
  21. package/lib/types/views/components/confirm-part/interface.d.ts +1 -1
  22. package/lib/types/views/components/dialog-part/interface.d.ts +1 -1
  23. package/lib/types/views/components/global-zone/GlobalZone.d.ts +17 -0
  24. package/lib/types/views/components/sidebar/interface.d.ts +1 -1
  25. package/lib/umd/index.js +12 -12
  26. package/package.json +30 -17
  27. package/lib/types/services/focus/focus.service.d.ts +0 -40
package/lib/index.css CHANGED
@@ -1 +1 @@
1
- .univer-ui-plugin-sheets-font-family{overflow:hidden;width:120px;font-size:var(--font-size-xs);text-overflow:ellipsis;white-space:nowrap}.univer-ui-plugin-sheets-font-family-item{font-size:var(--font-size-xs)}.univer-ui-plugin-sheets-font-size{width:28px;height:24px;font-size:var(--font-size-xs)}.univer-ui-plugin-sheets-font-size-input{height:24px;line-height:24px;background-color:transparent;border:none}.univer-ui-plugin-sheets-font-size-input input{font-size:var(--font-size-xs);background-color:transparent}.univer-menu-item-no-hover{background:none}.univer-menu-item-content{display:inline-flex;gap:var(--margin-xs);align-items:center}.univer-menu-item-selectable{position:relative;padding-left:var(--padding-xl)}.univer-menu-item-selectable-icon{position:absolute;left:0;display:inline-flex;align-items:center;font-size:var(--font-size-lg)}.univer-menu-item-more-icon{font-size:var(--font-size-sm);color:rgb(var(--text-color))}.univer-app-layout{display:flex;flex-direction:column;height:100%;background-color:rgb(var(--bg-color))}.univer-app-container{position:relative;display:flex;flex:1;flex-direction:column}.univer-app-container-header{position:relative;z-index:10;width:100%}.univer-app-container-wrapper{display:grid;grid-template-columns:1fr auto;height:100%}.univer-app-container-content{position:relative;overflow:hidden;display:grid;grid-template-rows:auto 1fr;flex:1;background-color:rgb(var(--bg-color-secondary));border-bottom:1px solid rgb(var(--border-color))}.univer-app-container-canvas{position:relative}.univer-app-container-sidebar{height:100%}.univer-toolbar-btn{cursor:pointer;display:flex;align-items:center;justify-content:center;min-width:24px;height:24px;padding:0;font-size:var(--font-size-lg);color:rgb(var(--text-color));background-color:transparent;border:none;border-radius:var(--border-radius-base);outline:none}.univer-toolbar-btn:not([disabled]):hover{background-color:rgb(var(--grey-100))}.univer-toolbar-btn[disabled]{cursor:not-allowed;color:rgb(var(--grey-200))}.univer-toolbar-btn-active{background-color:rgb(var(--grey-100))}.univer-headerbar{user-select:none;position:relative}.univer-headerbar>.univer-header-menu{position:absolute;top:0;right:0;display:flex;box-sizing:border-box;height:100%}.univer-headerbar>.univer-header-menu>div{user-select:none;display:inline-flex;align-items:center;height:28px;margin-left:4px;padding:2px 4px;text-align:center;border-radius:4px}.univer-headerbar>.univer-header-menu>div:hover{background-color:rgb(var(--grey-300))}.univer-menubar{display:flex;gap:var(--margin-xs);align-items:center;justify-content:center;height:32px}.univer-menubar-item{cursor:pointer;display:block;padding:var(--padding-xs) var(--padding-sm);font-size:var(--font-size-xs);font-weight:400;border-radius:var(--border-radius-base);transition:all .1s ease-in-out}.univer-menubar-item:hover:not(.univer-menubar-item-active){background:rgb(var(--grey-300))}.univer-menubar-item-active{color:rgb(var(--color-white));background:rgb(var(--primary-color))}.univer-toolbar{user-select:none;position:relative;display:flex;align-items:center;box-sizing:border-box;height:32px;font-size:var(--font-size-base);color:rgb(var(--text-color));background-color:rgb(var(--bg-color-secondary));border-bottom:1px solid rgb(var(--border-color))}.univer-toolbar-container{display:flex;gap:var(--margin-xs);align-items:center;justify-content:center;box-sizing:border-box;height:100%;margin:0 auto}.univer-toolbar-more{max-width:80%}.univer-toolbar-more-container{display:grid;gap:var(--margin-xs) 0;box-sizing:border-box;padding:var(--padding-sm);background-color:rgb(var(--bg-color-secondary));border-radius:var(--border-radius-base);box-shadow:var(--box-shadow-base)}.univer-toolbar-more-container .univer-toolbar-group{flex-wrap:wrap}.univer-toolbar-more-container .univer-toolbar-group:not(:last-child):after{content:initial}.univer-toolbar-group{display:flex;gap:var(--margin-xs);align-items:center}.univer-toolbar-group:not(:last-child,:empty):after{content:"";display:block;width:1px;height:20px;background-color:rgb(var(--border-color))}.univer-toolbar-item-select-button{cursor:pointer;position:relative;overflow:hidden;display:flex;gap:var(--margin-xs);align-items:center;height:24px;padding-right:18px;font-size:var(--font-size-lg);border-radius:var(--border-radius-base)}.univer-toolbar-item-select-button-disabled{cursor:not-allowed;color:rgb(var(--grey-200))}.univer-toolbar-item-select-button:hover,.univer-toolbar-item-select-button:hover .univer-toolbar-item-select-button-label{background-color:rgb(var(--grey-100))}.univer-toolbar-item-select-button-label{position:relative;z-index:1;display:flex;align-items:center;height:100%;padding:0 var(--padding-xs)}.univer-toolbar-item-select-button-label:hover{background-color:rgb(var(--grey-300))!important}.univer-toolbar-item-select-button-arrow{position:absolute;top:0;left:0;display:flex;align-items:center;justify-content:flex-end;box-sizing:border-box;width:100%;height:100%;padding-right:var(--padding-xs);font-size:10px;color:rgb(var(--grey-400))}.univer-toolbar-item-select-button-arrow:hover{background-color:rgb(var(--grey-300))}.univer-toolbar-item-select{cursor:pointer;position:relative;display:flex;gap:var(--margin-xs);align-items:center;height:24px;padding:0 var(--padding-xs);font-size:var(--font-size-lg);border-radius:var(--border-radius-base)}.univer-toolbar-item-select-disabled{cursor:not-allowed;color:rgb(var(--grey-200))}.univer-toolbar-item-select:hover{background-color:rgb(var(--grey-100));border-radius:var(--border-radius-base)}.univer-toolbar-item-select-arrow{display:flex;align-items:center;height:100%;font-size:10px;color:rgb(var(--grey-400))}.univer-toolbar-item-select-arrow-disabled{cursor:not-allowed;color:rgb(var(--grey-200))}.univer-sidebar{position:relative;transform:translate(100%);box-sizing:border-box;width:0;height:100%;color:rgb(var(--text-color));transition:all .15s}.univer-sidebar.univer-sidebar-open{transform:translate(0);width:380px}.univer-sidebar-container{overflow-y:auto;display:grid;grid-template-rows:auto 1fr auto;box-sizing:border-box;width:100%;height:0;min-height:100%;margin:auto;background-color:rgb(var(--bg-color-secondary));border-bottom:1px solid rgb(var(--border-color));border-left:1px solid rgb(var(--border-color))}.univer-sidebar-header{position:sticky;top:0;display:flex;align-items:center;justify-content:space-between;height:44px;padding:var(--padding-xl) var(--padding-xl) 0;font-size:var(--font-size-lg);font-weight:500;background:rgb(var(--bg-color-secondary))}.univer-sidebar-header-close{cursor:pointer;color:rgb(var(--text-color-secondary))}.univer-sidebar-body{padding:0 var(--padding-xl)}.univer-sidebar-footer{position:sticky;bottom:0;padding:var(--padding-xl);background:rgb(var(--bg-color-secondary))}.univer-zen-zone{position:absolute;display:none}.univer-zen-zone-open{z-index:100;top:0;left:0;display:block;width:100%;height:100%;background:rgb(var(--bg-color))}.univer-zen-zone-close{display:none}.univer-notification{position:fixed;z-index:1000;display:flex;flex-direction:column;align-items:flex-end;justify-content:center;box-sizing:border-box;margin:var(--margin-xs) 0}.univer-notification-notice{display:flex;gap:var(--margin-xs);justify-content:space-between;width:280px;padding:var(--padding-lg);font-size:var(--font-size-lg);background-color:rgb(var(--color-white));border-radius:var(--border-radius-base);box-shadow:var(--box-shadow-lg)}.univer-notification-notice-wrapper{margin:var(--margin-xs) var(--margin-base)}.univer-notification-notice-content{display:inline-flex;gap:var(--margin-xs);align-items:center;align-items:flex-start}.univer-notification-notice-close{cursor:pointer;display:flex;align-items:center;justify-content:center;width:fit-content;height:fit-content;padding:var(--padding-xs);color:rgb(var(--text-color-secondary));border-radius:var(--border-radius-base);outline:none;transition:background-color .2s}.univer-notification-notice-close:hover{background-color:rgb(var(--bg-color-hover))}.univer-notification-icon{padding:var(--padding-xs)}.univer-notification-icon-success{color:rgb(var(--success-color))}.univer-notification-icon-info{color:rgb(var(--info-color))}.univer-notification-icon-warning{color:rgb(var(--warning-color))}.univer-notification-icon-error{color:rgb(var(--error-color))}.univer-notification-content-container{display:inline-flex;flex-direction:column;gap:var(--margin-xs);align-items:flex-start;padding-top:var(--padding-xs)}.univer-notification-title{color:rgb(var(--text-color))}.univer-notification-content{color:rgb(var(--text-color-secondary))}.univer-notification-content-ellipsis{overflow:hidden;display:-webkit-box;text-overflow:ellipsis;-webkit-box-orient:vertical}.univer-notification-top,.univer-notification-topLeft,.univer-notification-topRight{top:0}.univer-notification-bottom,.univer-notification-bottomRight,.univer-notification-bottomLeft{bottom:0}.univer-notification-bottomRight,.univer-notification-topRight{right:0}.univer-notification-fade{overflow:hidden;transition:all .3s}.univer-notification-fade-appear-prepare{opacity:0}.univer-notification-fade-appear-start{transform:translate(100%);opacity:0}.univer-notification-fade-appear-active{transform:translate(0);opacity:1}.univer-notification-fade-appear,.univer-notification-fade-enter{opacity:0;animation-play-state:paused;animation-duration:.3s;animation-timing-function:cubic-bezier(.55,0,.55,.2);animation-fill-mode:both}.univer-notification-fade-leave{animation-duration:.3s;animation-timing-function:cubic-bezier(.55,0,.55,.2);animation-fill-mode:both;animation-play-state:paused}.univer-notification-fade-appear.univer-notification-fade-appear-active,.univer-notification-fade-enter.univer-notification-fade-enter-active{animation-name:univer-notification-fade-in;animation-play-state:running}.univer-notification-fade-leave.univer-notification-fade-leave-active{animation-name:univer-notification-fade-out;animation-play-state:running}@keyframes univer-notification-fade-in{0%{opacity:0}to{opacity:1}}@keyframes univer-notification-fade-out{0%{opacity:1}to{opacity:0}}.univer-shortcut-panel-group-title{height:40px;font-size:13px;font-weight:700;line-height:40px}.univer-shortcut-panel-item{display:flex;justify-content:space-between;height:40px;font-size:13px;line-height:40px}.univer-shortcut-panel-item-title{overflow:hidden;flex-grow:1;flex-shrink:1;max-width:200px;text-overflow:ellipsis;text-wrap:nowrap}.univer-shortcut-panel-item-shortcut{flex-grow:0;flex-shrink:0}.univer-shortcut-panel-item:not(:last-of-type){border-bottom:1px solid rgb(var(--grey-200))}
1
+ .univer-ui-plugin-sheets-font-family{overflow:hidden;width:120px;font-size:var(--font-size-xs);text-overflow:ellipsis;white-space:nowrap}.univer-ui-plugin-sheets-font-family-item{font-size:var(--font-size-xs)}.univer-ui-plugin-sheets-font-size{width:28px;height:24px;font-size:var(--font-size-xs)}.univer-ui-plugin-sheets-font-size-input{height:24px;line-height:24px;background-color:transparent;border:none}.univer-ui-plugin-sheets-font-size-input input{font-size:var(--font-size-xs);background-color:transparent}.univer-menu-item-no-hover{background:none}.univer-menu-item-content{display:inline-flex;gap:var(--margin-xs);align-items:center}.univer-menu-item-selectable{position:relative;padding-left:var(--padding-xl)}.univer-menu-item-selectable-icon{position:absolute;left:0;display:inline-flex;align-items:center;font-size:var(--font-size-lg)}.univer-menu-item-more-icon{font-size:var(--font-size-sm);color:rgb(var(--text-color))}.univer-app-layout{display:flex;flex-direction:column;height:100%;background-color:rgb(var(--bg-color))}.univer-app-container{position:relative;display:flex;flex:1;flex-direction:column}.univer-app-container-header{position:relative;z-index:10;width:100%}.univer-app-container-wrapper{display:grid;grid-template-columns:1fr auto;height:100%;overflow:hidden}.univer-app-container-content{position:relative;overflow:hidden;display:grid;grid-template-rows:auto 1fr;flex:1;background-color:rgb(var(--bg-color-secondary));border-bottom:1px solid rgb(var(--border-color))}.univer-app-container-canvas{position:relative}.univer-app-container-sidebar{height:100%}.univer-toolbar-btn{cursor:pointer;display:flex;align-items:center;justify-content:center;min-width:24px;height:24px;padding:0;font-size:var(--font-size-lg);color:rgb(var(--text-color));background-color:transparent;border:none;border-radius:var(--border-radius-base);outline:none}.univer-toolbar-btn:not([disabled]):hover{background-color:rgb(var(--grey-100))}.univer-toolbar-btn[disabled]{cursor:not-allowed;color:rgb(var(--grey-200))}.univer-toolbar-btn-active{background-color:rgb(var(--grey-100))}.univer-headerbar{user-select:none;position:relative}.univer-headerbar>.univer-header-menu{position:absolute;top:0;right:0;display:flex;box-sizing:border-box;height:100%}.univer-headerbar>.univer-header-menu>div{user-select:none;display:inline-flex;align-items:center;height:28px;margin-left:4px;padding:2px 4px;text-align:center;border-radius:4px}.univer-headerbar>.univer-header-menu>div:hover{background-color:rgb(var(--grey-300))}.univer-menubar{display:flex;gap:var(--margin-xs);align-items:center;justify-content:center;height:32px}.univer-menubar-item{cursor:pointer;display:block;padding:var(--padding-xs) var(--padding-sm);font-size:var(--font-size-xs);font-weight:400;border-radius:var(--border-radius-base);transition:all .1s ease-in-out}.univer-menubar-item:hover:not(.univer-menubar-item-active){background:rgb(var(--grey-300))}.univer-menubar-item-active{color:rgb(var(--color-white));background:rgb(var(--primary-color))}.univer-toolbar{user-select:none;position:relative;display:flex;align-items:center;box-sizing:border-box;height:32px;font-size:var(--font-size-base);color:rgb(var(--text-color));background-color:rgb(var(--bg-color-secondary));border-bottom:1px solid rgb(var(--border-color))}.univer-toolbar-container{display:flex;gap:var(--margin-xs);align-items:center;justify-content:center;box-sizing:border-box;height:100%;margin:0 auto}.univer-toolbar-more{max-width:80%}.univer-toolbar-more-container{display:grid;gap:var(--margin-xs) 0;box-sizing:border-box;padding:var(--padding-sm);background-color:rgb(var(--bg-color-secondary));border-radius:var(--border-radius-base);box-shadow:var(--box-shadow-base)}.univer-toolbar-more-container .univer-toolbar-group{flex-wrap:wrap}.univer-toolbar-more-container .univer-toolbar-group:not(:last-child):after{content:initial}.univer-toolbar-group{display:flex;gap:var(--margin-xs);align-items:center}.univer-toolbar-group:not(:last-child,:empty):after{content:"";display:block;width:1px;height:20px;background-color:rgb(var(--border-color))}.univer-toolbar-item-select-button{cursor:pointer;position:relative;overflow:hidden;display:flex;gap:var(--margin-xs);align-items:center;height:24px;padding-right:18px;font-size:var(--font-size-lg);border-radius:var(--border-radius-base)}.univer-toolbar-item-select-button-disabled{cursor:not-allowed;color:rgb(var(--grey-200))}.univer-toolbar-item-select-button:hover,.univer-toolbar-item-select-button:hover .univer-toolbar-item-select-button-label{background-color:rgb(var(--grey-100))}.univer-toolbar-item-select-button-label{position:relative;z-index:1;display:flex;align-items:center;height:100%;padding:0 var(--padding-xs)}.univer-toolbar-item-select-button-label:hover{background-color:rgb(var(--grey-300))!important}.univer-toolbar-item-select-button-arrow{position:absolute;top:0;left:0;display:flex;align-items:center;justify-content:flex-end;box-sizing:border-box;width:100%;height:100%;padding-right:var(--padding-xs);font-size:10px;color:rgb(var(--grey-400))}.univer-toolbar-item-select-button-arrow:hover{background-color:rgb(var(--grey-300))}.univer-toolbar-item-select{cursor:pointer;position:relative;display:flex;gap:var(--margin-xs);align-items:center;height:24px;padding:0 var(--padding-xs);font-size:var(--font-size-lg);border-radius:var(--border-radius-base)}.univer-toolbar-item-select-disabled{cursor:not-allowed;color:rgb(var(--grey-200))}.univer-toolbar-item-select:hover{background-color:rgb(var(--grey-100));border-radius:var(--border-radius-base)}.univer-toolbar-item-select-arrow{display:flex;align-items:center;height:100%;font-size:10px;color:rgb(var(--grey-400))}.univer-toolbar-item-select-arrow-disabled{cursor:not-allowed;color:rgb(var(--grey-200))}.univer-sidebar{position:relative;transform:translate(100%);box-sizing:border-box;width:0;height:100%;color:rgb(var(--text-color));transition:all .15s}.univer-sidebar.univer-sidebar-open{transform:translate(0);width:380px}.univer-sidebar-container{overflow-y:auto;display:grid;grid-template-rows:auto 1fr auto;box-sizing:border-box;width:100%;height:0;min-height:100%;margin:auto;background-color:rgb(var(--bg-color-secondary));border-bottom:1px solid rgb(var(--border-color));border-left:1px solid rgb(var(--border-color))}.univer-sidebar-header{position:sticky;top:0;display:flex;align-items:center;justify-content:space-between;height:44px;padding:var(--padding-xl) var(--padding-xl) 0;font-size:var(--font-size-lg);font-weight:500;background:rgb(var(--bg-color-secondary))}.univer-sidebar-header-close{cursor:pointer;color:rgb(var(--text-color-secondary))}.univer-sidebar-body{padding:0 var(--padding-xl)}.univer-sidebar-footer{position:sticky;bottom:0;padding:var(--padding-xl);background:rgb(var(--bg-color-secondary))}.univer-zen-zone{position:absolute;display:none}.univer-zen-zone-open{z-index:100;top:0;left:0;display:block;width:100%;height:100%;background:rgb(var(--bg-color))}.univer-zen-zone-close{display:none}.univer-notification{position:fixed;z-index:1000;display:flex;flex-direction:column;align-items:flex-end;justify-content:center;box-sizing:border-box;margin:var(--margin-xs) 0}.univer-notification-notice{display:flex;gap:var(--margin-xs);justify-content:space-between;width:280px;padding:var(--padding-lg);font-size:var(--font-size-lg);background-color:rgb(var(--color-white));border-radius:var(--border-radius-base);box-shadow:var(--box-shadow-lg)}.univer-notification-notice-wrapper{margin:var(--margin-xs) var(--margin-base)}.univer-notification-notice-content{display:inline-flex;gap:var(--margin-xs);align-items:center;align-items:flex-start}.univer-notification-notice-close{cursor:pointer;display:flex;align-items:center;justify-content:center;width:fit-content;height:fit-content;padding:var(--padding-xs);color:rgb(var(--text-color-secondary));border-radius:var(--border-radius-base);outline:none;transition:background-color .2s}.univer-notification-notice-close:hover{background-color:rgb(var(--bg-color-hover))}.univer-notification-icon{padding:var(--padding-xs)}.univer-notification-icon-success{color:rgb(var(--success-color))}.univer-notification-icon-info{color:rgb(var(--info-color))}.univer-notification-icon-warning{color:rgb(var(--warning-color))}.univer-notification-icon-error{color:rgb(var(--error-color))}.univer-notification-content-container{display:inline-flex;flex-direction:column;gap:var(--margin-xs);align-items:flex-start;padding-top:var(--padding-xs)}.univer-notification-title{color:rgb(var(--text-color))}.univer-notification-content{color:rgb(var(--text-color-secondary))}.univer-notification-content-ellipsis{overflow:hidden;display:-webkit-box;text-overflow:ellipsis;-webkit-box-orient:vertical}.univer-notification-top,.univer-notification-topLeft,.univer-notification-topRight{top:0}.univer-notification-bottom,.univer-notification-bottomRight,.univer-notification-bottomLeft{bottom:0}.univer-notification-bottomRight,.univer-notification-topRight{right:0}.univer-notification-fade{overflow:hidden;transition:all .3s}.univer-notification-fade-appear-prepare{opacity:0}.univer-notification-fade-appear-start{transform:translate(100%);opacity:0}.univer-notification-fade-appear-active{transform:translate(0);opacity:1}.univer-notification-fade-appear,.univer-notification-fade-enter{opacity:0;animation-play-state:paused;animation-duration:.3s;animation-timing-function:cubic-bezier(.55,0,.55,.2);animation-fill-mode:both}.univer-notification-fade-leave{animation-duration:.3s;animation-timing-function:cubic-bezier(.55,0,.55,.2);animation-fill-mode:both;animation-play-state:paused}.univer-notification-fade-appear.univer-notification-fade-appear-active,.univer-notification-fade-enter.univer-notification-fade-enter-active{animation-name:univer-notification-fade-in;animation-play-state:running}.univer-notification-fade-leave.univer-notification-fade-leave-active{animation-name:univer-notification-fade-out;animation-play-state:running}@keyframes univer-notification-fade-in{0%{opacity:0}to{opacity:1}}@keyframes univer-notification-fade-out{0%{opacity:1}to{opacity:0}}.univer-global-zone{position:absolute;display:none}.univer-global-zone-open{z-index:100;top:0;left:0;display:block;width:100%;height:100%;background:rgb(var(--bg-color))}.univer-global-zone-close{display:none}.univer-shortcut-panel-group-title{height:40px;font-size:13px;font-weight:700;line-height:40px}.univer-shortcut-panel-item{display:flex;justify-content:space-between;height:40px;font-size:13px;line-height:40px}.univer-shortcut-panel-item-title{overflow:hidden;flex-grow:1;flex-shrink:1;max-width:200px;text-overflow:ellipsis;text-wrap:nowrap}.univer-shortcut-panel-item-shortcut{flex-grow:0;flex-shrink:0}.univer-shortcut-panel-item:not(:last-of-type){border-bottom:1px solid rgb(var(--grey-200))}
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Copyright 2023-present DreamNum Inc.
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 { IOperation } from '@univerjs/core';
17
+ export declare const SetEditorResizeOperation: IOperation;
@@ -0,0 +1,35 @@
1
+ /**
2
+ * Copyright 2023-present DreamNum Inc.
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 { IDocumentData, Nullable } from '@univerjs/core';
17
+ import React from 'react';
18
+ import type { IEditorCanvasStyle } from '../../services/editor/editor.service';
19
+ type MyComponentProps = React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>;
20
+ export interface ITextEditorProps {
21
+ id: string;
22
+ snapshot?: IDocumentData;
23
+ resizeCallBack?: (editor: Nullable<HTMLDivElement>) => void;
24
+ cancelDefaultResizeListener?: boolean;
25
+ isSheetEditor?: boolean;
26
+ canvasStyle?: IEditorCanvasStyle;
27
+ value?: string;
28
+ }
29
+ /**
30
+ * The component to render toolbar item label and menu item label.
31
+ * @param props
32
+ * @returns
33
+ */
34
+ export declare function TextEditor(props: ITextEditorProps & MyComponentProps): JSX.Element | null;
35
+ export {};
@@ -20,8 +20,7 @@ import { Injector } from '@wendellhu/redi';
20
20
  import type { ComponentType } from 'react';
21
21
  import React from 'react';
22
22
  import type { Observable } from 'rxjs';
23
- import { IFocusService } from '../../services/focus/focus.service';
24
- import { LayoutService } from '../../services/layout/layout.service';
23
+ import { ILayoutService } from '../../services/layout/layout.service';
25
24
  import type { IWorkbenchOptions } from './ui.controller';
26
25
  import { IUIController } from './ui.controller';
27
26
  export declare enum DesktopUIPart {
@@ -48,15 +47,14 @@ export declare class DesktopUIController extends Disposable implements IDesktopU
48
47
  private readonly _injector;
49
48
  private readonly _lifecycleService;
50
49
  private readonly _renderManagerService;
51
- private readonly _focusService;
52
- private readonly _layoutService?;
50
+ private readonly _layoutService;
53
51
  private _headerComponents;
54
52
  private _headerMenuComponents;
55
53
  private _contentComponents;
56
54
  private _footerComponents;
57
55
  private _componentRegistered$;
58
56
  componentRegistered$: Observable<void>;
59
- constructor(_injector: Injector, _lifecycleService: LifecycleService, _renderManagerService: IRenderManagerService, _focusService: IFocusService, _layoutService?: LayoutService | undefined);
57
+ constructor(_injector: Injector, _lifecycleService: LifecycleService, _renderManagerService: IRenderManagerService, _layoutService: ILayoutService);
60
58
  bootstrapWorkbench(options: IWorkbenchOptions): void;
61
59
  private _initializeEngine;
62
60
  registerComponent(part: DesktopUIPart, component: () => React.ComponentType): IDisposable;
@@ -30,8 +30,7 @@ export { DesktopConfirmService } from './services/confirm/desktop-confirm.servic
30
30
  export { DesktopContextMenuService, type IContextMenuHandler, IContextMenuService, } from './services/contextmenu/contextmenu.service';
31
31
  export { DesktopDialogService } from './services/dialog/desktop-dialog.service';
32
32
  export { IDialogService } from './services/dialog/dialog.service';
33
- export { IFocusService } from './services/focus/focus.service';
34
- export { LayoutService } from './services/layout/layout.service';
33
+ export { ILayoutService } from './services/layout/layout.service';
35
34
  export { type ICustomComponentProps, type IDisplayMenuItem, type IMenuButtonItem, type IMenuItem, type IMenuItemFactory, type IMenuSelectorItem, type IValueOption, MenuGroup, MenuItemType, MenuPosition, } from './services/menu/menu';
36
35
  export { DesktopMenuService, IMenuService } from './services/menu/menu.service';
37
36
  export { DesktopMessageService } from './services/message/desktop-message.service';
@@ -39,6 +38,8 @@ export { IMessageService } from './services/message/message.service';
39
38
  export { DesktopNotificationService } from './services/notification/desktop-notification.service';
40
39
  export { INotificationService } from './services/notification/notification.service';
41
40
  export { DesktopPlatformService, IPlatformService } from './services/platform/platform.service';
41
+ export { DesktopGlobalZoneService } from './services/global-zone/desktop-global-zone.service';
42
+ export { IGlobalZoneService } from './services/global-zone/global-zone.service';
42
43
  export { KeyCode, MetaKeys } from './services/shortcut/keycode';
43
44
  export { DesktopShortcutService, type IShortcutItem, IShortcutService } from './services/shortcut/shortcut.service';
44
45
  export { DesktopSidebarService } from './services/sidebar/desktop-sidebar.service';
@@ -47,3 +48,6 @@ export { IZenZoneService } from './services/zen-zone/zen-zone.service';
47
48
  export { UniverUIPlugin } from './ui-plugin';
48
49
  export * from './utils';
49
50
  export { type IConfirmPartMethodOptions } from './views/components/confirm-part/interface';
51
+ export { IEditorService, EditorService } from './services/editor/editor.service';
52
+ export { TextEditor } from './components/editor/TextEditor';
53
+ export { SetEditorResizeOperation } from './commands/operations/editor/set-editor-resize.operation';
@@ -13,50 +13,6 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
- declare const _default: {
17
- uiToolbar: {
18
- start: string;
19
- insert: string;
20
- formulas: string;
21
- data: string;
22
- view: string;
23
- others: string;
24
- };
25
- fontFamily: {
26
- TimesNewRoman: string;
27
- Arial: string;
28
- Tahoma: string;
29
- Verdana: string;
30
- MicrosoftYaHei: string;
31
- SimSun: string;
32
- SimHei: string;
33
- Kaiti: string;
34
- FangSong: string;
35
- NSimSun: string;
36
- STXinwei: string;
37
- STXingkai: string;
38
- STLiti: string;
39
- HanaleiFill: string;
40
- Anton: string;
41
- Pacifico: string;
42
- };
43
- 'shortcut-panel': {
44
- title: string;
45
- };
46
- shortcut: {
47
- undo: string;
48
- redo: string;
49
- cut: string;
50
- copy: string;
51
- paste: string;
52
- };
53
- 'common-edit': string;
54
- 'toggle-shortcut-panel': string;
55
- clipboard: {
56
- authentication: {
57
- title: string;
58
- content: string;
59
- };
60
- };
61
- };
62
- export default _default;
16
+ import type zhCN from './zh-CN';
17
+ declare const locale: typeof zhCN;
18
+ export default locale;
@@ -13,7 +13,7 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
- declare const _default: {
16
+ declare const locale: {
17
17
  uiToolbar: {
18
18
  start: string;
19
19
  insert: string;
@@ -59,4 +59,4 @@ declare const _default: {
59
59
  };
60
60
  };
61
61
  };
62
- export default _default;
62
+ export default locale;
@@ -14,8 +14,8 @@
14
14
  * limitations under the License.
15
15
  */
16
16
  import type { IDisposable } from '@wendellhu/redi';
17
- import { type Subject } from 'rxjs';
18
- import { type IConfirmPartMethodOptions } from '../../views/components/confirm-part/interface';
17
+ import type { Subject } from 'rxjs';
18
+ import type { IConfirmPartMethodOptions } from '../../views/components/confirm-part/interface';
19
19
  export declare const IConfirmService: import("@wendellhu/redi").IdentifierDecorator<IConfirmService>;
20
20
  export interface IConfirmService {
21
21
  readonly confirmOptions$: Subject<IConfirmPartMethodOptions[]>;
@@ -15,7 +15,7 @@
15
15
  */
16
16
  import type { IDisposable } from '@wendellhu/redi';
17
17
  import { Subject } from 'rxjs';
18
- import { type IConfirmPartMethodOptions } from '../../views/components/confirm-part/interface';
18
+ import type { IConfirmPartMethodOptions } from '../../views/components/confirm-part/interface';
19
19
  import type { IConfirmService } from './confirm.service';
20
20
  export declare class DesktopConfirmService implements IConfirmService {
21
21
  private _confirmOptions;
@@ -16,7 +16,7 @@
16
16
  import { Disposable } from '@univerjs/core';
17
17
  import type { IDisposable } from '@wendellhu/redi';
18
18
  import { Subject } from 'rxjs';
19
- import { type IDialogPartMethodOptions } from '../../views/components/dialog-part/interface';
19
+ import type { IDialogPartMethodOptions } from '../../views/components/dialog-part/interface';
20
20
  import type { IDialogService } from './dialog.service';
21
21
  export declare class DesktopDialogService extends Disposable implements IDialogService {
22
22
  private _dialogOptions;
@@ -14,8 +14,8 @@
14
14
  * limitations under the License.
15
15
  */
16
16
  import type { IDisposable } from '@wendellhu/redi';
17
- import { type Subject } from 'rxjs';
18
- import { type IDialogPartMethodOptions } from '../../views/components/dialog-part/interface';
17
+ import type { Subject } from 'rxjs';
18
+ import type { IDialogPartMethodOptions } from '../../views/components/dialog-part/interface';
19
19
  export declare const IDialogService: import("@wendellhu/redi").IdentifierDecorator<IDialogService>;
20
20
  export interface IDialogService {
21
21
  open(params: IDialogPartMethodOptions): IDisposable;
@@ -0,0 +1,147 @@
1
+ /**
2
+ * Copyright 2023-present DreamNum Inc.
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 { DocumentDataModel, IDocumentBody, IDocumentData, IPosition, Nullable } from '@univerjs/core';
17
+ import { Disposable, IUniverInstanceService } from '@univerjs/core';
18
+ import type { IDisposable } from '@wendellhu/redi';
19
+ import type { Observable } from 'rxjs';
20
+ import type { IRender, ISuccinctTextRangeParam } from '@univerjs/engine-render';
21
+ import { IRenderManagerService } from '@univerjs/engine-render';
22
+ export interface IEditorStateParam extends Partial<IPosition> {
23
+ visible?: boolean;
24
+ }
25
+ export interface IEditorCanvasStyle {
26
+ fontSize?: number;
27
+ }
28
+ export interface IEditorConfigParam {
29
+ editorUnitId: string;
30
+ initialSnapshot?: IDocumentData;
31
+ cancelDefaultResizeListener?: boolean;
32
+ canvasStyle?: IEditorCanvasStyle;
33
+ isSingle?: boolean;
34
+ isSheetEditor: boolean;
35
+ }
36
+ export interface IEditorSetParam extends IEditorConfigParam, IEditorStateParam {
37
+ render: IRender;
38
+ documentDataModel: DocumentDataModel;
39
+ editorDom: HTMLDivElement;
40
+ }
41
+ export interface IEditorSetValueParam {
42
+ editorUnitId: string;
43
+ body: IDocumentBody;
44
+ }
45
+ export interface IEditorInputFormulaParam {
46
+ editorUnitId: string;
47
+ formulaString: string;
48
+ }
49
+ declare class Editor {
50
+ private _param;
51
+ constructor(_param: IEditorSetParam);
52
+ get documentDataModel(): DocumentDataModel;
53
+ get editorUnitId(): string;
54
+ get cancelDefaultResizeListener(): boolean | undefined;
55
+ get render(): IRender;
56
+ get isSingle(): boolean | undefined;
57
+ getBoundingClientRect(): DOMRect;
58
+ isVisible(): boolean | undefined;
59
+ isSheetEditor(): boolean;
60
+ getValue(): string;
61
+ getBody(): IDocumentBody | undefined;
62
+ update(param: IEditorStateParam): void;
63
+ verticalAlign(): void;
64
+ updateCanvasStyle(): void;
65
+ }
66
+ export interface IEditorService {
67
+ getEditor(id?: string): Readonly<Nullable<Editor>>;
68
+ setState(param: IEditorStateParam, id: string): void;
69
+ register(config: IEditorConfigParam, container: HTMLDivElement): IDisposable;
70
+ unRegister(editorUnitId: string): void;
71
+ isVisible(id: string): Nullable<boolean>;
72
+ inputFormula$: Observable<IEditorInputFormulaParam>;
73
+ setFormula(formulaString: string): void;
74
+ resize$: Observable<string>;
75
+ resize(id: string): void;
76
+ getAllEditor(): Map<string, Editor>;
77
+ setOperationSheetUnitId(unitId: Nullable<string>): void;
78
+ getOperationSheetUnitId(): Nullable<string>;
79
+ setOperationSheetSubUnitId(sheetId: Nullable<string>): void;
80
+ getOperationSheetSubUnitId(): Nullable<string>;
81
+ isEditor(editorUnitId: string): boolean;
82
+ isSheetEditor(editorUnitId: string): boolean;
83
+ changeEditorFocus$: Observable<unknown>;
84
+ changeEditorFocus(): void;
85
+ blur$: Observable<unknown>;
86
+ blur(): void;
87
+ focus$: Observable<ISuccinctTextRangeParam>;
88
+ focus(editorUnitId?: string): void;
89
+ setValue$: Observable<IEditorSetValueParam>;
90
+ valueChange$: Observable<Readonly<Editor>>;
91
+ setValue(val: string, editorUnitId?: string): void;
92
+ setRichValue(body: IDocumentBody, editorUnitId?: string): void;
93
+ getFirstEditor(): Editor;
94
+ }
95
+ export declare class EditorService extends Disposable implements IEditorService, IDisposable {
96
+ private readonly _currentUniverService;
97
+ private readonly _renderManagerService;
98
+ private _editors;
99
+ private readonly _state$;
100
+ readonly state$: Observable<Nullable<IEditorStateParam>>;
101
+ private _currentSheetUnitId;
102
+ private _currentSheetSubUnitId;
103
+ private readonly _inputFormula$;
104
+ readonly inputFormula$: Observable<IEditorInputFormulaParam>;
105
+ private readonly _resize$;
106
+ readonly resize$: Observable<string>;
107
+ private readonly _changeEditorFocus$;
108
+ readonly changeEditorFocus$: Observable<unknown>;
109
+ private readonly _blur$;
110
+ readonly blur$: Observable<unknown>;
111
+ private readonly _focus$;
112
+ readonly focus$: Observable<ISuccinctTextRangeParam>;
113
+ private readonly _setValue$;
114
+ readonly setValue$: Observable<IEditorSetValueParam>;
115
+ private readonly _valueChange$;
116
+ readonly valueChange$: Observable<Readonly<Editor>>;
117
+ constructor(_currentUniverService: IUniverInstanceService, _renderManagerService: IRenderManagerService);
118
+ isEditor(editorUnitId: string): boolean;
119
+ isSheetEditor(editorUnitId: string): boolean;
120
+ changeEditorFocus(): void;
121
+ blur(): void;
122
+ focus(editorUnitId?: string): void;
123
+ setFormula(formulaString: string, editorUnitId?: string): void;
124
+ setValue(val: string, editorUnitId?: string): void;
125
+ getValue(id?: string): string | undefined;
126
+ setRichValue(body: IDocumentBody, editorUnitId?: string): void;
127
+ getRichValue(id?: string): IDocumentBody | undefined;
128
+ dispose(): void;
129
+ getEditor(id?: string): Readonly<Nullable<Editor>>;
130
+ getAllEditor(): Map<string, Editor>;
131
+ getFirstEditor(): Editor;
132
+ resize(unitId: string): void;
133
+ setState(param: IEditorStateParam, id: string): void;
134
+ isVisible(id: string): boolean | undefined;
135
+ setOperationSheetUnitId(unitId: Nullable<string>): void;
136
+ getOperationSheetUnitId(): Nullable<string>;
137
+ setOperationSheetSubUnitId(sheetId: Nullable<string>): void;
138
+ getOperationSheetSubUnitId(): Nullable<string>;
139
+ register(config: IEditorConfigParam, container: HTMLDivElement): IDisposable;
140
+ unRegister(editorUnitId: string): void;
141
+ private _refreshValueChange;
142
+ private _getCurrentEditorUnitId;
143
+ private _refresh;
144
+ private _getBlank;
145
+ }
146
+ export declare const IEditorService: import("@wendellhu/redi").IdentifierDecorator<IEditorService>;
147
+ export {};
@@ -0,0 +1,29 @@
1
+ /**
2
+ * Copyright 2023-present DreamNum Inc.
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 '@wendellhu/redi';
17
+ import type { ForwardRefExoticComponent } from 'react';
18
+ import { Subject } from 'rxjs';
19
+ import { ComponentManager } from '../../common/component-manager';
20
+ import type { IGlobalZoneService } from './global-zone.service';
21
+ export declare class DesktopGlobalZoneService implements IGlobalZoneService {
22
+ private readonly _componentManager;
23
+ readonly visible$: Subject<boolean>;
24
+ readonly componentKey$: Subject<string>;
25
+ constructor(_componentManager: ComponentManager);
26
+ set(key: string, component: ForwardRefExoticComponent<any>): IDisposable;
27
+ open(): void;
28
+ close(): void;
29
+ }
@@ -0,0 +1,25 @@
1
+ /**
2
+ * Copyright 2023-present DreamNum Inc.
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 '@wendellhu/redi';
17
+ import type { Subject } from 'rxjs';
18
+ export declare const IGlobalZoneService: import("@wendellhu/redi").IdentifierDecorator<IGlobalZoneService>;
19
+ export interface IGlobalZoneService {
20
+ readonly visible$: Subject<boolean>;
21
+ readonly componentKey$: Subject<string>;
22
+ set(key: string, component: any): IDisposable;
23
+ open(): void;
24
+ close(): void;
25
+ }
@@ -13,13 +13,50 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
+ import type { ContextService } from '@univerjs/core';
17
+ import { Disposable, ILogService, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
16
18
  import { type IDisposable } from '@wendellhu/redi';
19
+ type FocusHandlerFn = (unitId: string) => void;
20
+ export declare const FOCUSING_UNIVER = "FOCUSING_UNIVER";
21
+ export interface ILayoutService {
22
+ readonly isFocused: boolean;
23
+ /** Re-focus the currently focused Univer business instance. */
24
+ focus(): void;
25
+ /** Register a focus handler to focus on certain type of Univer unit. */
26
+ registerFocusHandler(type: UniverInstanceType, handler: FocusHandlerFn): IDisposable;
27
+ /** Register the root container element. */
28
+ registerRootContainerElement(container: HTMLElement): IDisposable;
29
+ /** Register a canvas element. */
30
+ registerCanvasElement(container: HTMLCanvasElement): IDisposable;
31
+ /** Register an element as a container, especially floating components like Dialogs and Notifications. */
32
+ registerContainerElement(container: HTMLElement): IDisposable;
33
+ checkElementInCurrentContainers(element: HTMLElement): boolean;
34
+ checkCanvasIsFocused(): boolean;
35
+ }
36
+ export declare const ILayoutService: import("@wendellhu/redi").IdentifierDecorator<ILayoutService>;
17
37
  /**
18
38
  * This service is responsible for storing layout information of the current
19
- * Univer application instance
39
+ * Univer application instance.
20
40
  */
21
- export declare class LayoutService {
22
- private _containers;
23
- registerContainer(container: HTMLElement): IDisposable;
24
- checkElementInCurrentApplicationScope(element: HTMLElement): boolean;
41
+ export declare class DesktopLayoutService extends Disposable implements ILayoutService {
42
+ private readonly _contextService;
43
+ private readonly _univerInstanceService;
44
+ private readonly _logService;
45
+ private _rootContainerElement;
46
+ private _isFocused;
47
+ get isFocused(): boolean;
48
+ private readonly _focusHandlers;
49
+ private _canvasContainers;
50
+ private _allContainers;
51
+ constructor(_contextService: ContextService, _univerInstanceService: IUniverInstanceService, _logService: ILogService);
52
+ focus(): void;
53
+ registerFocusHandler(type: UniverInstanceType, handler: FocusHandlerFn): IDisposable;
54
+ registerCanvasElement(container: HTMLCanvasElement): IDisposable;
55
+ registerRootContainerElement(container: HTMLElement): IDisposable;
56
+ registerContainerElement(container: HTMLElement): IDisposable;
57
+ checkElementInCurrentContainers(element: HTMLElement): boolean;
58
+ checkCanvasIsFocused(): boolean;
59
+ private _initUniverFocusListener;
60
+ private _initEditorStatus;
25
61
  }
62
+ export {};
@@ -16,12 +16,14 @@
16
16
  import { Disposable, ICommandService, IContextService } from '@univerjs/core';
17
17
  import type { IDisposable } from '@wendellhu/redi';
18
18
  import type { Observable } from 'rxjs';
19
- import { LayoutService } from '../layout/layout.service';
19
+ import { ILayoutService } from '../layout/layout.service';
20
20
  import { IPlatformService } from '../platform/platform.service';
21
21
  export interface IShortcutItem<P extends object = object> {
22
22
  /** This should reuse the corresponding command's id. */
23
23
  id: string;
24
+ /** Description of the shortcut. */
24
25
  description?: string;
26
+ /** If two shortcuts have the same binding, the one with higher priority would be check first. */
25
27
  priority?: number;
26
28
  /** A callback that will be triggered to examine if the shortcut should be invoked. */
27
29
  preconditions?: (contextService: IContextService) => boolean;
@@ -59,7 +61,7 @@ export declare class DesktopShortcutService extends Disposable implements IShort
59
61
  readonly shortcutChanged$: Observable<void>;
60
62
  private _forceEscaped;
61
63
  private _disable;
62
- constructor(_commandService: ICommandService, _platformService: IPlatformService, _contextService: IContextService, _layoutService?: LayoutService | undefined);
64
+ constructor(_commandService: ICommandService, _platformService: IPlatformService, _contextService: IContextService, _layoutService?: ILayoutService | undefined);
63
65
  setDisable(disable: boolean): void;
64
66
  getAllShortcuts(): IShortcutItem[];
65
67
  registerShortcut(shortcut: IShortcutItem): IDisposable;
@@ -15,7 +15,7 @@
15
15
  */
16
16
  import type { IDisposable } from '@wendellhu/redi';
17
17
  import { Subject } from 'rxjs';
18
- import { type ISidebarMethodOptions } from '../../views/components/sidebar/interface';
18
+ import type { ISidebarMethodOptions } from '../../views/components/sidebar/interface';
19
19
  import type { ISidebarService } from './sidebar.service';
20
20
  export declare class DesktopSidebarService implements ISidebarService {
21
21
  private _sidebarOptions;
@@ -15,7 +15,7 @@
15
15
  */
16
16
  import type { IDisposable } from '@wendellhu/redi';
17
17
  import type { Subject } from 'rxjs';
18
- import { type ISidebarMethodOptions } from '../../views/components/sidebar/interface';
18
+ import type { ISidebarMethodOptions } from '../../views/components/sidebar/interface';
19
19
  export declare const ISidebarService: import("@wendellhu/redi").IdentifierDecorator<ISidebarService>;
20
20
  export interface ISidebarService {
21
21
  readonly sidebarOptions$: Subject<ISidebarMethodOptions>;
@@ -14,7 +14,7 @@
14
14
  * limitations under the License.
15
15
  */
16
16
  import type { IConfirmProps } from '@univerjs/design';
17
- import { type ICustomLabelProps } from '../../../components/custom-label/CustomLabel';
17
+ import type { ICustomLabelProps } from '../../../components/custom-label/CustomLabel';
18
18
  export type IConfirmPartMethodOptions = {
19
19
  id: string;
20
20
  children?: ICustomLabelProps;
@@ -14,7 +14,7 @@
14
14
  * limitations under the License.
15
15
  */
16
16
  import type { IDialogProps } from '@univerjs/design';
17
- import { type ICustomLabelProps } from '../../../components/custom-label/CustomLabel';
17
+ import type { ICustomLabelProps } from '../../../components/custom-label/CustomLabel';
18
18
  export type IDialogPartMethodOptions = {
19
19
  id: string;
20
20
  children?: ICustomLabelProps;
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Copyright 2023-present DreamNum Inc.
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 React from 'react';
17
+ export declare function GlobalZone(): React.JSX.Element | null;
@@ -13,7 +13,7 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
- import { type ICustomLabelProps } from '../../../components/custom-label/CustomLabel';
16
+ import type { ICustomLabelProps } from '../../../components/custom-label/CustomLabel';
17
17
  export interface ISidebarMethodOptions {
18
18
  header?: ICustomLabelProps;
19
19
  children?: ICustomLabelProps;