@univerjs/sheets-ui 0.1.0-beta.2 → 0.1.0-beta.3
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/{LICENSE.txt → LICENSE} +0 -2
- package/lib/cjs/index.js +11 -11
- package/lib/es/index.js +6420 -7033
- package/lib/index.css +1 -1
- package/lib/types/commands/commands/__tests__/create-command-test-bed.d.ts +25 -0
- package/lib/types/{components/font-size/FontSize.d.ts → commands/commands/__tests__/hide-row-col-confirm.command.spec.d.ts} +1 -3
- package/lib/types/{components/font-family/FontFamily.d.ts → commands/commands/__tests__/remove-row-col-confirm.command.spec.d.ts} +1 -3
- package/lib/types/{components/font-family/FontFamilyItem.d.ts → commands/commands/__tests__/selection-utils.spec.d.ts} +1 -3
- package/lib/types/commands/commands/delete-range-move-left-confirm.command .d.ts +17 -0
- package/lib/types/commands/commands/delete-range-move-up-confirm.command.d.ts +17 -0
- package/lib/types/commands/commands/hide-row-col-confirm.command.d.ts +18 -0
- package/lib/types/commands/commands/insert-range-move-down-confirm.command.d.ts +17 -0
- package/lib/types/commands/commands/insert-range-move-right-confirm.command.d.ts +17 -0
- package/lib/types/commands/commands/remove-row-col-confirm.command.d.ts +18 -0
- package/lib/types/commands/commands/utils/selection-utils.d.ts +14 -0
- package/lib/types/components/font-family/index.d.ts +2 -2
- package/lib/types/components/font-family/interface.d.ts +0 -7
- package/lib/types/components/font-size/index.d.ts +1 -1
- package/lib/types/components/font-size/interface.d.ts +0 -9
- package/lib/types/controllers/header-menu.controller.d.ts +4 -2
- package/lib/types/controllers/menu/menu.d.ts +0 -8
- package/lib/types/controllers/menu/sheet.menu.d.ts +3 -3
- package/lib/types/controllers/shortcuts/utils.d.ts +24 -5
- package/lib/types/controllers/shortcuts/view.shortcut.d.ts +3 -0
- package/lib/types/index.d.ts +1 -1
- package/lib/types/locale/en-US.d.ts +7 -18
- package/lib/types/locale/zh-CN.d.ts +7 -18
- package/lib/types/services/auto-fill/rules.d.ts +1 -0
- package/lib/types/services/auto-fill/tools.d.ts +2 -2
- package/lib/types/services/clipboard/copy-content-cache.d.ts +2 -2
- package/lib/types/services/shortcut-experience.service.d.ts +45 -0
- package/lib/types/views/sheet-bar/sheet-bar-tabs/utils/slide-tab-bar.d.ts +3 -1
- package/lib/umd/index.js +11 -11
- package/package.json +48 -46
- /package/lib/types/views/count-bar/{zoom-slider.d.ts → ZoomSlider.d.ts} +0 -0
package/lib/index.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.univer-range-selector{overflow:hidden;display:flex;align-items:center;justify-content:space-between;padding:0 var(--padding-sm) 0 var(--padding-base);border:1px solid rgb(var(--border-color));border-radius:var(--border-radius-base)}.univer-range-selector-editor{cursor:text;overflow:hidden;display:inline-block;width:218px;height:20px;padding:6px 0;font-size:var(--font-size-xs);line-height:20px;text-wrap:nowrap;border:0;outline:0}.univer-range-selector-editor::selection{color:rgb(var(--color-white));background-color:rgb(var(--primary-color))}.univer-range-selector-editor:empty:before{content:attr(data-placeholder);color:rgb(var(--grey-400))}.univer-range-selector-icon{cursor:pointer;display:flex;align-items:center;justify-content:center;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-range-selector-icon:not([disabled]):hover{background-color:rgb(var(--grey-100))}.univer-range-selector-icon[disabled]{cursor:not-allowed;color:rgb(var(--grey-200))}.univer-range-selector-active{border-color:rgb(var(--primary-color))}.univer-range-selector-active .univer-range-selector-icon{color:rgb(var(--primary-color))}.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-sheets-ui-context-menu-input{display:flex;gap:var(--margin-sm);align-items:center}.univer-sheets-ui-context-menu-input-container{width:72px}.univer-sheets-ui-context-menu-input-number{height:24px}.univer-sheet-container{display:flex;align-items:center;justify-content:space-between;box-sizing:border-box;height:36px;padding:0 var(--padding-xl)}.univer-ui-plugin-sheets-border-panel{display:grid;gap:var(--margin-sm)}.univer-ui-plugin-sheets-border-panel-position{display:grid;grid-template-columns:repeat(5,1fr);gap:var(--margin-xxs);box-sizing:border-box;padding-bottom:var(--padding-base);border-bottom:1px solid rgb(var(--border-color))}.univer-ui-plugin-sheets-border-panel-position-item{display:flex;align-items:center;justify-content:center;width:24px;height:24px;font-size:var(--font-size-lg);border-radius:var(--border-radius-base)}.univer-ui-plugin-sheets-border-panel-position-item:hover{background-color:rgb(var(--bg-color-hover))}.univer-ui-plugin-sheets-border-panel-styles{display:flex;gap:var(--margin-xs);align-items:center;justify-content:space-around}.univer-ui-plugin-sheets-border-panel-board{box-sizing:border-box;padding:var(--padding-base);background-color:rgb(var(--bg-color-secondary));border:1px solid rgb(var(--border-color));border-radius:var(--border-radius-lg);box-shadow:var(--box-shadow-base)}.univer-ui-plugin-sheets-border-panel-button{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);transition:all .15s}.univer-ui-plugin-sheets-border-panel-button:hover{background-color:rgb(var(--bg-color-hover))}.univer-ui-plugin-sheets-border-panel-more-icon{font-size:10px;color:rgb(var(--grey-400))}.univer-count-bar{display:flex;flex:0 0 260px;justify-content:flex-end}.univer-editor-container{position:absolute;z-index:10;top:200px;left:100px;display:flex;width:100px;height:50px;border:1.5px solid rgb(var(--primary-color));outline:1.5px solid rgba(var(--primary-color-hover),.5);box-shadow:none}.univer-editor-container .univer-editor-input{position:relative;display:flex;width:100%;height:100%;background:#fff}.univer-formula-box{display:flex;box-sizing:border-box;height:28px;background:rgb(var(--bg-color-secondary));border-bottom:1px solid rgb(var(--border-color));transition:height .15s}.univer-formula-box .univer-name-ranges{box-sizing:border-box;width:80px;height:100%;padding:6px 0}.univer-formula-box .univer-name-ranges-input{height:100%;border-right:1px solid rgb(var(--border-color))}.univer-formula-box .univer-formula-bar{display:flex;width:100%;height:100%}.univer-formula-box .univer-formula-bar .univer-formula-icon{padding:6px 0}.univer-formula-box .univer-formula-bar .univer-formula-icon-wrapper{position:relative;display:flex;gap:var(--margin-xs);align-items:center;justify-content:center;box-sizing:border-box;width:80px;height:100%;font-size:var(--font-size-xs);border-right:1px solid rgb(var(--border-color))}.univer-formula-box .univer-formula-bar .univer-formula-icon-wrapper .univer-icon-container{cursor:pointer;display:flex;align-items:center;justify-content:center;font-size:var(--font-size-lg)}.univer-formula-box .univer-formula-bar .univer-formula-icon-wrapper .univer-icon-container-success.univer-formula-active{color:rgb(var(--success-color))}.univer-formula-box .univer-formula-bar .univer-formula-icon-wrapper .univer-icon-container-error.univer-formula-active{color:rgb(var(--error-color))}.univer-formula-box .univer-formula-bar .univer-formula-input{overflow:hidden;display:flex;flex:1;width:100%;padding:0 0 0 10px}.univer-formula-box .univer-formula-bar .univer-formula-input .univer-formula-content{position:relative;width:100%;height:100%;word-wrap:break-word;outline:none}.univer-formula-box .univer-formula-bar .univer-formula-input .univer-arrow-container{cursor:pointer;display:flex;align-items:center;justify-content:center;width:20px;height:100%;font-size:var(--font-size-xs);color:rgb(var(--text-color-secondary))}.univer-operate-container{position:absolute;z-index:1;right:0;left:0;width:0;height:0}.univer-auto-fill-popup-menu{display:grid;gap:var(--margin-xxs);align-items:center;box-sizing:border-box;min-width:128px;margin-top:0;margin-bottom:0;padding:var(--padding-sm);font-size:var(--font-size-base);background-color:rgb(var(--bg-color-secondary));border:1px solid rgb(var(--border-color));border-radius:var(--border-radius-lg);box-shadow:var(--box-shadow-lg)}.univer-auto-fill-popup-menu li{list-style:none}.univer-auto-fill-popup-menu-item{cursor:pointer;position:relative;display:flex;align-items:center;box-sizing:border-box;width:134px;height:28px;padding:var(--padding-xs) 0 var(--padding-xs) 36px;font-size:13px;font-weight:400;font-style:normal;line-height:20px;color:rgb(var(--black, #35322B));text-align:left;border-radius:4px;border-radius:var(--border-radius-base);transition:background .2s}.univer-auto-fill-popup-menu-item:hover{background-color:rgb(var(--bg-color-hover))}.univer-auto-fill-popup-menu-item-icon{position:absolute;top:50%;left:var(--padding-xs);transform:translateY(-50%);display:flex;align-items:center;justify-content:center}.univer-auto-fill-popup-menu-item-title{padding:var(--padding-xs) var(--padding-xs) var(--padding-xs) 0;vertical-align:middle}.univer-auto-fill-popup-menu-item-hide{color:rgb(var(--text-color-secondary))}.univer-auto-fill-popup-menu-item:hover{background:rgb(var(--grey-100))}.univer-btn-container{display:flex;align-items:center;justify-content:center;padding:3px;background:#fff;border:1px solid rgb(var(--grey-200, #E5E5E5));border-radius:4px}.univer-btn-container:hover,.univer-btn-container.univer-btn-container-expand{background:rgb(var(--grey-100, #f5f5f5))}.univer-sheet-bar{position:relative;display:flex;flex:1 1 0px;flex-direction:row;min-width:calc(100% - 592px);max-width:calc(100% - 260px);height:100%;background-color:rgb(var(--bg-color))}.univer-sheet-bar-options{display:flex;flex-direction:row;align-items:center;margin:var(--margin-xxs);transition:display .2s}.univer-sheet-bar-options-divider:after{content:"";display:block;width:1px;height:16px;margin:0 var(--margin-xs);background-color:rgb(var(--grey-400))}.univer-sheet-bar-btn{cursor:pointer;display:flex;align-items:center;justify-content:center;width:24px;height:24px;padding:0;font-size:var(--font-size-lg);color:rgb(var(--text-color-secondary-darker));background-color:transparent;border:none;border-radius:var(--border-radius-base);outline:none}.univer-sheet-bar-btn:not([disabled]):hover{background-color:rgb(var(--bg-color-hover))}.univer-sheet-bar-btn[disabled]{cursor:not-allowed;color:rgb(var(--grey-200))}.univer-sheet-bar-menu{display:grid;gap:var(--margin-xxs);align-items:center;box-sizing:border-box;padding:var(--padding-sm);background-color:rgb(var(--bg-color-secondary));border:1px solid rgb(var(--border-color));border-radius:var(--border-radius-lg);box-shadow:var(--box-shadow-lg)}.univer-sheet-bar-menu li{list-style:none}.univer-sheet-bar-menu-item{cursor:pointer;position:relative;display:flex;box-sizing:border-box;padding:var(--padding-xs) 24px;color:rgb(var(--text-color));border-radius:var(--border-radius-base);transition:background .2s}.univer-sheet-bar-menu-item:hover{background-color:rgb(var(--bg-color-hover))}.univer-sheet-bar-menu-item-icon{position:absolute;top:50%;left:var(--margin-xxs);transform:translateY(-50%);color:transparent}.univer-sheet-bar-menu-item-hide .univer-sheet-bar-menu-item-icon{display:flex;align-items:center;justify-content:center;width:16px;height:16px;color:rgb(var(--grey-400))}.univer-sheet-bar-menu-item-select{font-weight:500;color:rgb(var(--primary-color))}.univer-sheet-bar-menu-item-select .univer-sheet-bar-menu-item-icon{display:flex;align-items:center;justify-content:center;width:16px;height:16px;color:rgb(var(--primary-color))}.univer-sheet-bar-menu-item-label{font-size:var(--font-size-xs);font-weight:400;line-height:20px}.univer-slide-tab-bar-container{overflow:hidden;max-width:calc(100% - 112px)}.univer-slide-tab-bar-container .univer-slide-tab-bar{-webkit-user-select:none;user-select:none;overflow:hidden;display:flex;flex-direction:row;align-items:center;padding:var(--padding-xs) 6px;transition:box-shadow .2s}.univer-slide-tab-item{cursor:pointer;-webkit-user-select:none;user-select:none;display:flex;flex-direction:row;flex-grow:1;align-items:center;box-sizing:border-box;margin:0 var(--margin-xxs);font-size:var(--font-size-xs);line-height:16px;color:rgb(var(--grey-1000));border-radius:var(--border-radius-base)}.univer-slide-tab-item:not(.univer-slide-tab-active):hover{background-color:rgb(var(--bg-color-hover))}.univer-slide-tab-item .univer-slide-tab-span{box-sizing:border-box;padding:var(--padding-xs) var(--padding-sm);white-space:nowrap;border:2px solid transparent;border-radius:var(--border-radius-base)}.univer-slide-tab-item .univer-slide-tab-span-edit{cursor:text;outline:none}.univer-slide-tab-item .univer-slide-tab-span-edit::selection{color:rgb(var(--color-white));background-color:rgb(var(--primary-color))}.univer-slide-tab-active{font-weight:700;color:rgb(var(--primary-color));background-color:rgb(var(--bg-color-secondary));box-shadow:0 0 8px #00000014;transition:box-shadow .2s}.univer-status-bar{display:flex;align-items:center;max-width:332px}.univer-status-bar.univer-single-mode{max-width:136px}.univer-status-bar-div{width:1px;height:16px;margin-left:10px;background:rgb(var(--grey-400, #CCC))}.univer-statistic-list{display:flex}.univer-statistic-list-column{flex-direction:column}.univer-statistic-list-column .univer-statistic-item{font-size:12px;line-height:140%;color:rgb(var(--grey-500))}.univer-statistic-item{cursor:default;overflow:hidden;display:flex;justify-content:start;max-width:106px;margin-right:8px;font-size:12px;font-weight:400;font-style:normal;line-height:20px;color:rgb(var(--grey-900));text-align:center;text-overflow:ellipsis;white-space:nowrap}.univer-statistic-picker{display:grid;gap:var(--margin-sm);align-items:center;box-sizing:border-box;width:196px;padding:var(--padding-base);font-size:var(--font-size-xs);background-color:rgb(var(--color-white));border:1px solid rgb(var(--border-color));border-radius:var(--border-radius-lg);box-shadow:var(--box-shadow-lg)}.univer-statistic-picker-item{display:flex;align-items:center;justify-content:start}.univer-statistic-more{transform:rotate(90deg);display:flex;align-items:center;justify-content:center;width:24px;height:24px;font-size:12px;color:rgb(var(--grey-600, #E8E8E8));border-radius:4px}.univer-statistic-more:hover{background:rgb(var(--grey-300, #E8E8E8))}
|
|
1
|
+
.univer-range-selector{overflow:hidden;display:flex;align-items:center;justify-content:space-between;padding:0 var(--padding-sm) 0 var(--padding-base);border:1px solid rgb(var(--border-color));border-radius:var(--border-radius-base)}.univer-range-selector-editor{cursor:text;overflow:hidden;display:inline-block;width:218px;height:20px;padding:6px 0;font-size:var(--font-size-xs);line-height:20px;text-wrap:nowrap;border:0;outline:0}.univer-range-selector-editor::selection{color:rgb(var(--color-white));background-color:rgb(var(--primary-color))}.univer-range-selector-editor:empty:before{content:attr(data-placeholder);color:rgb(var(--grey-400))}.univer-range-selector-icon{cursor:pointer;display:flex;align-items:center;justify-content:center;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-range-selector-icon:not([disabled]):hover{background-color:rgb(var(--grey-100))}.univer-range-selector-icon[disabled]{cursor:not-allowed;color:rgb(var(--grey-200))}.univer-range-selector-active{border-color:rgb(var(--primary-color))}.univer-range-selector-active .univer-range-selector-icon{color:rgb(var(--primary-color))}.univer-sheets-ui-context-menu-input{display:flex;gap:var(--margin-sm);align-items:center}.univer-sheets-ui-context-menu-input-container{width:72px}.univer-sheets-ui-context-menu-input-number{height:24px}.univer-sheet-container{display:flex;align-items:center;justify-content:space-between;box-sizing:border-box;height:36px;padding:0 var(--padding-xl)}.univer-ui-plugin-sheets-border-panel{display:grid;gap:var(--margin-sm)}.univer-ui-plugin-sheets-border-panel-position{display:grid;grid-template-columns:repeat(5,1fr);gap:var(--margin-xxs);box-sizing:border-box;padding-bottom:var(--padding-base);border-bottom:1px solid rgb(var(--border-color))}.univer-ui-plugin-sheets-border-panel-position-item{display:flex;align-items:center;justify-content:center;width:24px;height:24px;font-size:var(--font-size-lg);border-radius:var(--border-radius-base)}.univer-ui-plugin-sheets-border-panel-position-item:hover{background-color:rgb(var(--bg-color-hover))}.univer-ui-plugin-sheets-border-panel-styles{display:flex;gap:var(--margin-xs);align-items:center;justify-content:space-around}.univer-ui-plugin-sheets-border-panel-board{box-sizing:border-box;padding:var(--padding-base);background-color:rgb(var(--bg-color-secondary));border:1px solid rgb(var(--border-color));border-radius:var(--border-radius-lg);box-shadow:var(--box-shadow-base)}.univer-ui-plugin-sheets-border-panel-button{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);transition:all .15s}.univer-ui-plugin-sheets-border-panel-button:hover{background-color:rgb(var(--bg-color-hover))}.univer-ui-plugin-sheets-border-panel-more-icon{font-size:10px;color:rgb(var(--grey-400))}.univer-count-bar{display:flex;flex:0 0 260px;justify-content:flex-end}.univer-editor-container{position:absolute;z-index:10;top:200px;left:100px;display:flex;width:100px;height:50px;border:1.5px solid rgb(var(--primary-color));outline:1.5px solid rgba(var(--primary-color-hover),.5);box-shadow:none}.univer-editor-container .univer-editor-input{position:relative;display:flex;width:100%;height:100%;background:#fff}.univer-formula-box{display:flex;box-sizing:border-box;height:28px;background:rgb(var(--bg-color-secondary));border-bottom:1px solid rgb(var(--border-color));transition:height .15s}.univer-formula-box .univer-name-ranges{box-sizing:border-box;width:80px;height:100%;padding:6px 0}.univer-formula-box .univer-name-ranges-input{height:100%;border-right:1px solid rgb(var(--border-color))}.univer-formula-box .univer-formula-bar{display:flex;width:100%;height:100%}.univer-formula-box .univer-formula-bar .univer-formula-icon{padding:6px 0}.univer-formula-box .univer-formula-bar .univer-formula-icon-wrapper{position:relative;display:flex;gap:var(--margin-xs);align-items:center;justify-content:center;box-sizing:border-box;width:80px;height:100%;font-size:var(--font-size-xs);border-right:1px solid rgb(var(--border-color))}.univer-formula-box .univer-formula-bar .univer-formula-icon-wrapper .univer-icon-container{cursor:pointer;display:flex;align-items:center;justify-content:center;font-size:var(--font-size-lg)}.univer-formula-box .univer-formula-bar .univer-formula-icon-wrapper .univer-icon-container-success.univer-formula-active{color:rgb(var(--success-color))}.univer-formula-box .univer-formula-bar .univer-formula-icon-wrapper .univer-icon-container-error.univer-formula-active{color:rgb(var(--error-color))}.univer-formula-box .univer-formula-bar .univer-formula-input{overflow:hidden;display:flex;flex:1;width:100%;padding:0 0 0 10px}.univer-formula-box .univer-formula-bar .univer-formula-input .univer-formula-content{position:relative;width:100%;height:100%;word-wrap:break-word;outline:none}.univer-formula-box .univer-formula-bar .univer-formula-input .univer-arrow-container{cursor:pointer;display:flex;align-items:center;justify-content:center;width:20px;height:100%;font-size:var(--font-size-xs);color:rgb(var(--text-color-secondary))}.univer-operate-container{position:absolute;z-index:1;right:0;left:0;width:0;height:0}.univer-auto-fill-popup-menu{display:grid;gap:var(--margin-xxs);align-items:center;box-sizing:border-box;min-width:128px;margin-top:0;margin-bottom:0;padding:var(--padding-sm);font-size:var(--font-size-base);background-color:rgb(var(--bg-color-secondary));border:1px solid rgb(var(--border-color));border-radius:var(--border-radius-lg);box-shadow:var(--box-shadow-lg)}.univer-auto-fill-popup-menu li{list-style:none}.univer-auto-fill-popup-menu-item{cursor:pointer;position:relative;display:flex;align-items:center;box-sizing:border-box;width:134px;height:28px;padding:var(--padding-xs) 0 var(--padding-xs) 36px;font-size:13px;font-weight:400;font-style:normal;line-height:20px;color:rgb(var(--black, #35322B));text-align:left;border-radius:4px;border-radius:var(--border-radius-base);transition:background .2s}.univer-auto-fill-popup-menu-item:hover{background-color:rgb(var(--bg-color-hover))}.univer-auto-fill-popup-menu-item-icon{position:absolute;top:50%;left:var(--padding-xs);transform:translateY(-50%);display:flex;align-items:center;justify-content:center}.univer-auto-fill-popup-menu-item-title{padding:var(--padding-xs) var(--padding-xs) var(--padding-xs) 0;vertical-align:middle}.univer-auto-fill-popup-menu-item-hide{color:rgb(var(--text-color-secondary))}.univer-auto-fill-popup-menu-item:hover{background:rgb(var(--grey-100))}.univer-btn-container{display:flex;align-items:center;justify-content:center;padding:3px;background:#fff;border:1px solid rgb(var(--grey-200, #E5E5E5));border-radius:4px}.univer-btn-container:hover,.univer-btn-container.univer-btn-container-expand{background:rgb(var(--grey-100, #f5f5f5))}.univer-sheet-bar{position:relative;display:flex;flex:1 1 0px;flex-direction:row;min-width:calc(100% - 592px);max-width:calc(100% - 260px);height:100%;background-color:rgb(var(--bg-color))}.univer-sheet-bar-options{display:flex;flex-direction:row;align-items:center;margin:var(--margin-xxs);transition:display .2s}.univer-sheet-bar-options-divider:after{content:"";display:block;width:1px;height:16px;margin:0 var(--margin-xs);background-color:rgb(var(--grey-400))}.univer-sheet-bar-btn{cursor:pointer;display:flex;align-items:center;justify-content:center;width:24px;height:24px;padding:0;font-size:var(--font-size-lg);color:rgb(var(--text-color-secondary-darker));background-color:transparent;border:none;border-radius:var(--border-radius-base);outline:none}.univer-sheet-bar-btn:not([disabled]):hover{background-color:rgb(var(--bg-color-hover))}.univer-sheet-bar-btn[disabled]{cursor:not-allowed;color:rgb(var(--grey-200))}.univer-sheet-bar-menu{display:grid;gap:var(--margin-xxs);align-items:center;box-sizing:border-box;padding:var(--padding-sm);background-color:rgb(var(--bg-color-secondary));border:1px solid rgb(var(--border-color));border-radius:var(--border-radius-lg);box-shadow:var(--box-shadow-lg)}.univer-sheet-bar-menu li{list-style:none}.univer-sheet-bar-menu-item{cursor:pointer;position:relative;display:flex;box-sizing:border-box;padding:var(--padding-xs) 24px;color:rgb(var(--text-color));border-radius:var(--border-radius-base);transition:background .2s}.univer-sheet-bar-menu-item:hover{background-color:rgb(var(--bg-color-hover))}.univer-sheet-bar-menu-item-icon{position:absolute;top:50%;left:var(--margin-xxs);transform:translateY(-50%);color:transparent}.univer-sheet-bar-menu-item-hide .univer-sheet-bar-menu-item-icon{display:flex;align-items:center;justify-content:center;width:16px;height:16px;color:rgb(var(--grey-400))}.univer-sheet-bar-menu-item-select{font-weight:500;color:rgb(var(--primary-color))}.univer-sheet-bar-menu-item-select .univer-sheet-bar-menu-item-icon{display:flex;align-items:center;justify-content:center;width:16px;height:16px;color:rgb(var(--primary-color))}.univer-sheet-bar-menu-item-label{font-size:var(--font-size-xs);font-weight:400;line-height:20px}.univer-slide-tab-bar-container{overflow:hidden;max-width:calc(100% - 112px)}.univer-slide-tab-bar-container .univer-slide-tab-bar{-webkit-user-select:none;user-select:none;overflow:hidden;display:flex;flex-direction:row;align-items:center;padding:var(--padding-xs) 6px;transition:box-shadow .2s}.univer-slide-tab-item{cursor:pointer;-webkit-user-select:none;user-select:none;display:flex;flex-direction:row;flex-grow:1;align-items:center;box-sizing:border-box;margin:0 var(--margin-xxs);font-size:var(--font-size-xs);line-height:16px;color:rgb(var(--grey-1000));border-radius:var(--border-radius-base)}.univer-slide-tab-item:not(.univer-slide-tab-active):hover{background-color:rgb(var(--bg-color-hover))}.univer-slide-tab-item .univer-slide-tab-span{box-sizing:border-box;padding:var(--padding-xs) var(--padding-sm);white-space:nowrap;border:2px solid transparent;border-radius:var(--border-radius-base)}.univer-slide-tab-item .univer-slide-tab-span-edit{cursor:text;outline:none}.univer-slide-tab-item .univer-slide-tab-span-edit::selection{color:rgb(var(--color-white));background-color:rgb(var(--primary-color))}.univer-slide-tab-active{font-weight:700;color:rgb(var(--primary-color));background-color:rgb(var(--bg-color-secondary));box-shadow:0 0 8px #00000014;transition:box-shadow .2s}.univer-slide-tab-item-dropdown{-webkit-user-select:none;user-select:none;min-width:auto!important}.univer-status-bar{display:flex;align-items:center;max-width:332px}.univer-status-bar.univer-single-mode{max-width:136px}.univer-status-bar-div{width:1px;height:16px;margin-left:10px;background:rgb(var(--grey-400, #CCC))}.univer-statistic-list{display:flex}.univer-statistic-list-column{flex-direction:column}.univer-statistic-list-column .univer-statistic-item{font-size:12px;line-height:140%;color:rgb(var(--grey-500))}.univer-statistic-item{cursor:default;overflow:hidden;display:flex;justify-content:start;max-width:106px;margin-right:8px;font-size:12px;font-weight:400;font-style:normal;line-height:20px;color:rgb(var(--grey-900));text-align:center;text-overflow:ellipsis;white-space:nowrap}.univer-statistic-picker{display:grid;gap:var(--margin-sm);align-items:center;box-sizing:border-box;width:196px;padding:var(--padding-base);font-size:var(--font-size-xs);background-color:rgb(var(--color-white));border:1px solid rgb(var(--border-color));border-radius:var(--border-radius-lg);box-shadow:var(--box-shadow-lg)}.univer-statistic-picker-item{display:flex;align-items:center;justify-content:start}.univer-statistic-more{transform:rotate(90deg);display:flex;align-items:center;justify-content:center;width:24px;height:24px;font-size:12px;color:rgb(var(--grey-600, #E8E8E8));border-radius:4px}.univer-statistic-more:hover{background:rgb(var(--grey-300, #E8E8E8))}
|
|
@@ -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 { IWorkbookData, Workbook } from '@univerjs/core';
|
|
17
|
+
import { Univer } from '@univerjs/core';
|
|
18
|
+
import type { Dependency } from '@wendellhu/redi';
|
|
19
|
+
import { Injector } from '@wendellhu/redi';
|
|
20
|
+
export interface ITestBed {
|
|
21
|
+
univer: Univer;
|
|
22
|
+
get: Injector['get'];
|
|
23
|
+
sheet: Workbook;
|
|
24
|
+
}
|
|
25
|
+
export declare function createCommandTestBed(workbookConfig?: IWorkbookData, dependencies?: Dependency[]): ITestBed;
|
|
@@ -13,6 +13,4 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
|
|
17
|
-
import type { IFontSizeProps } from './interface';
|
|
18
|
-
export declare const FontSize: (props: IFontSizeProps) => React.JSX.Element;
|
|
16
|
+
export {};
|
|
@@ -13,6 +13,4 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
|
|
17
|
-
import type { IFontFamilyProps } from './interface';
|
|
18
|
-
export declare const FontFamily: (props: IFontFamilyProps) => React.JSX.Element;
|
|
16
|
+
export {};
|
|
@@ -13,6 +13,4 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
|
|
17
|
-
import type { IFontFamilyItemProps } from './interface';
|
|
18
|
-
export declare const FontFamilyItem: (props: IFontFamilyItemProps) => React.JSX.Element;
|
|
16
|
+
export {};
|
|
@@ -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 { ICommand } from '@univerjs/core';
|
|
17
|
+
export declare const DeleteRangeMoveLeftConfirmCommand: ICommand;
|
|
@@ -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 { ICommand } from '@univerjs/core';
|
|
17
|
+
export declare const DeleteRangeMoveUpConfirmCommand: ICommand;
|
|
@@ -0,0 +1,18 @@
|
|
|
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 { ICommand } from '@univerjs/core';
|
|
17
|
+
export declare const HideRowConfirmCommand: ICommand;
|
|
18
|
+
export declare const HideColConfirmCommand: ICommand;
|
|
@@ -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 { ICommand } from '@univerjs/core';
|
|
17
|
+
export declare const InsertRangeMoveDownConfirmCommand: ICommand;
|
|
@@ -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 { ICommand } from '@univerjs/core';
|
|
17
|
+
export declare const InsertRangeMoveRightConfirmCommand: ICommand;
|
|
@@ -0,0 +1,18 @@
|
|
|
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 { ICommand } from '@univerjs/core';
|
|
17
|
+
export declare const RemoveRowConfirmCommand: ICommand;
|
|
18
|
+
export declare const RemoveColConfirmCommand: ICommand;
|
|
@@ -44,3 +44,17 @@ export declare function expandToContinuousRange(startRange: IRange, directions:
|
|
|
44
44
|
export declare function expandToWholeSheet(worksheet: Worksheet): IRange;
|
|
45
45
|
export declare function getStartRange(range: IRange, primary: Nullable<ISelectionCell>, direction: Direction): IRange;
|
|
46
46
|
export declare function checkIfShrink(selection: ISelection, direction: Direction, worksheet: Worksheet): boolean;
|
|
47
|
+
/**
|
|
48
|
+
* Determine whether the entire row is selected
|
|
49
|
+
* @param allRowRanges Range of all rows
|
|
50
|
+
* @param ranges Range of selected rows
|
|
51
|
+
* @returns Whether the entire row is selected
|
|
52
|
+
*/
|
|
53
|
+
export declare function isAllRowsCovered(allRowRanges: IRange[], ranges: IRange[]): boolean;
|
|
54
|
+
/**
|
|
55
|
+
* Determine whether the entire column is selected
|
|
56
|
+
* @param allColumnRanges Range of all columns
|
|
57
|
+
* @param ranges Range of selected columns
|
|
58
|
+
* @returns Whether the entire column is selected
|
|
59
|
+
*/
|
|
60
|
+
export declare function isAllColumnsCovered(allColumnRanges: IRange[], ranges: IRange[]): boolean;
|
|
@@ -13,6 +13,6 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
export { FontFamily } from './FontFamily';
|
|
17
|
-
export { FontFamilyItem } from './FontFamilyItem';
|
|
18
16
|
export { FONT_FAMILY_COMPONENT, FONT_FAMILY_ITEM_COMPONENT } from './interface';
|
|
17
|
+
export { FontFamily } from '@univerjs/ui';
|
|
18
|
+
export { FontFamilyItem } from '@univerjs/ui';
|
|
@@ -13,12 +13,5 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
import type { ICustomComponentProps } from '@univerjs/ui';
|
|
17
16
|
export declare const FONT_FAMILY_COMPONENT = "UI_PLUGIN_SHEETS_FONT_FAMILY_COMPONENT";
|
|
18
|
-
export interface IFontFamilyProps extends ICustomComponentProps<string> {
|
|
19
|
-
value: string;
|
|
20
|
-
}
|
|
21
17
|
export declare const FONT_FAMILY_ITEM_COMPONENT = "UI_PLUGIN_SHEETS_FONT_FAMILY_ITEM_COMPONENT";
|
|
22
|
-
export interface IFontFamilyItemProps extends ICustomComponentProps<string> {
|
|
23
|
-
value: string;
|
|
24
|
-
}
|
|
@@ -13,13 +13,4 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
import type { ICustomComponentProps } from '@univerjs/ui';
|
|
17
|
-
import type { Observable } from 'rxjs';
|
|
18
16
|
export declare const FONT_SIZE_COMPONENT = "UI_PLUGIN_SHEETS_FONT_SIZE_COMPONENT";
|
|
19
|
-
export interface IFontSizeProps extends ICustomComponentProps<string> {
|
|
20
|
-
value: string;
|
|
21
|
-
min: number;
|
|
22
|
-
max: number;
|
|
23
|
-
onChange: (value: string) => void;
|
|
24
|
-
disabled$?: Observable<boolean>;
|
|
25
|
-
}
|
|
@@ -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 { Disposable, IUniverInstanceService } from '@univerjs/core';
|
|
16
|
+
import { Disposable, ICommandService, IUniverInstanceService } from '@univerjs/core';
|
|
17
17
|
import { IRenderManagerService } from '@univerjs/engine-render';
|
|
18
18
|
import { SelectionManagerService } from '@univerjs/sheets';
|
|
19
19
|
import { IContextMenuService } from '@univerjs/ui';
|
|
@@ -27,15 +27,17 @@ export declare class HeaderMenuController extends Disposable {
|
|
|
27
27
|
private readonly _currentUniverService;
|
|
28
28
|
private readonly _renderManagerService;
|
|
29
29
|
private readonly _contextMenuService;
|
|
30
|
+
private readonly _commandService;
|
|
30
31
|
private readonly _selectionManagerService;
|
|
31
32
|
private _hoverRect;
|
|
32
33
|
private _hoverMenu;
|
|
33
34
|
private _currentColumn;
|
|
34
35
|
private _observers;
|
|
35
|
-
constructor(_sheetSkeletonManagerService: SheetSkeletonManagerService, _currentUniverService: IUniverInstanceService, _renderManagerService: IRenderManagerService, _contextMenuService: IContextMenuService, _selectionManagerService: SelectionManagerService);
|
|
36
|
+
constructor(_sheetSkeletonManagerService: SheetSkeletonManagerService, _currentUniverService: IUniverInstanceService, _renderManagerService: IRenderManagerService, _contextMenuService: IContextMenuService, _commandService: ICommandService, _selectionManagerService: SelectionManagerService);
|
|
36
37
|
dispose(): void;
|
|
37
38
|
private _initialize;
|
|
38
39
|
private _initialHover;
|
|
39
40
|
private _initialHoverMenu;
|
|
40
41
|
private _getSheetObject;
|
|
42
|
+
private _getSelectionOnColumn;
|
|
41
43
|
}
|
|
@@ -26,14 +26,6 @@ export declare function BoldMenuItemFactory(accessor: IAccessor): IMenuButtonIte
|
|
|
26
26
|
export declare function ItalicMenuItemFactory(accessor: IAccessor): IMenuButtonItem;
|
|
27
27
|
export declare function UnderlineMenuItemFactory(accessor: IAccessor): IMenuButtonItem;
|
|
28
28
|
export declare function StrikeThroughMenuItemFactory(accessor: IAccessor): IMenuButtonItem;
|
|
29
|
-
export declare const FONT_SIZE_CHILDREN: {
|
|
30
|
-
label: string;
|
|
31
|
-
value: number;
|
|
32
|
-
}[];
|
|
33
|
-
export declare const FONT_FAMILY_CHILDREN: {
|
|
34
|
-
label: string;
|
|
35
|
-
value: string;
|
|
36
|
-
}[];
|
|
37
29
|
export declare function FontFamilySelectorMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<string>;
|
|
38
30
|
export declare function FontSizeSelectorMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<number>;
|
|
39
31
|
export declare function ResetTextColorMenuItemFactory(accessor: IAccessor): IMenuButtonItem;
|
|
@@ -15,10 +15,10 @@
|
|
|
15
15
|
*/
|
|
16
16
|
import type { IMenuButtonItem, IMenuSelectorItem } from '@univerjs/ui';
|
|
17
17
|
import type { IAccessor } from '@wendellhu/redi';
|
|
18
|
-
export declare function DeleteSheetMenuItemFactory(): IMenuButtonItem;
|
|
18
|
+
export declare function DeleteSheetMenuItemFactory(accessor: IAccessor): IMenuButtonItem;
|
|
19
19
|
export declare function CopySheetMenuItemFactory(): IMenuButtonItem;
|
|
20
20
|
export declare function RenameSheetMenuItemFactory(): IMenuButtonItem;
|
|
21
21
|
export declare function ChangeColorSheetMenuItemFactory(): IMenuSelectorItem<string>;
|
|
22
|
-
export declare function HideSheetMenuItemFactory(): IMenuButtonItem;
|
|
22
|
+
export declare function HideSheetMenuItemFactory(accessor: IAccessor): IMenuButtonItem;
|
|
23
23
|
export declare function UnHideSheetMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<any>;
|
|
24
|
-
export declare function ShowMenuItemFactory(): IMenuButtonItem;
|
|
24
|
+
export declare function ShowMenuItemFactory(accessor: IAccessor): IMenuButtonItem;
|
|
@@ -14,11 +14,30 @@
|
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
16
|
import type { IContextService } from '@univerjs/core';
|
|
17
|
-
export declare function
|
|
17
|
+
export declare function whenSheetFocused(contextService: IContextService): boolean;
|
|
18
|
+
/**
|
|
19
|
+
* Requires the currently focused unit to be Workbook and the sheet editor is focused but not activated.
|
|
20
|
+
* @param contextService
|
|
21
|
+
* @returns
|
|
22
|
+
*/
|
|
23
|
+
export declare function whenSheetEditorFocused(contextService: IContextService): boolean;
|
|
24
|
+
/**
|
|
25
|
+
* Requires the currently focused unit to be Workbook and the sheet editor is activated.
|
|
26
|
+
* @param contextService
|
|
27
|
+
* @returns
|
|
28
|
+
*/
|
|
29
|
+
export declare function whenSheetEditorActivated(contextService: IContextService): boolean;
|
|
18
30
|
export declare function whenEditorActivated(contextService: IContextService): boolean;
|
|
19
|
-
|
|
20
|
-
|
|
31
|
+
/**
|
|
32
|
+
* Requires the currently focused editor is a formula editor.
|
|
33
|
+
* @param contextService
|
|
34
|
+
* @returns
|
|
35
|
+
*/
|
|
21
36
|
export declare function whenFormulaEditorFocused(contextService: IContextService): boolean;
|
|
22
|
-
|
|
37
|
+
/**
|
|
38
|
+
* Requires the currently focused editor is a formula editor, and it is activated.
|
|
39
|
+
* @param contextService
|
|
40
|
+
* @returns
|
|
41
|
+
*/
|
|
42
|
+
export declare function whenFormulaEditorActivated(contextService: IContextService): boolean;
|
|
23
43
|
export declare function whenEditorDidNotInputFormulaActivated(contextService: IContextService): boolean;
|
|
24
|
-
export declare function whenEditorNotActivatedOrFormulaActivated(contextService: IContextService): boolean;
|
|
@@ -15,5 +15,8 @@
|
|
|
15
15
|
*/
|
|
16
16
|
import type { IShortcutItem } from '@univerjs/ui';
|
|
17
17
|
export declare const ZoomInShortcutItem: IShortcutItem;
|
|
18
|
+
export declare const PreventDefaultZoomInShortcutItem: IShortcutItem;
|
|
18
19
|
export declare const ZoomOutShortcutItem: IShortcutItem;
|
|
20
|
+
export declare const PreventDefaultZoomOutShortcutItem: IShortcutItem;
|
|
19
21
|
export declare const ResetZoomShortcutItem: IShortcutItem;
|
|
22
|
+
export declare const PreventDefaultResetZoomShortcutItem: IShortcutItem;
|
package/lib/types/index.d.ts
CHANGED
|
@@ -27,7 +27,7 @@ export { VIEWPORT_KEY } from './common/keys';
|
|
|
27
27
|
export { RangeSelector } from './components/range-selector/RangeSelector';
|
|
28
28
|
export { AutoFillController } from './controllers/auto-fill.controller';
|
|
29
29
|
export { PASTE_SPECIAL_MENU_ID } from './controllers/menu/menu';
|
|
30
|
-
export {
|
|
30
|
+
export { whenFormulaEditorActivated } from './controllers/shortcuts/utils';
|
|
31
31
|
export { getCoordByCell, getCoordByOffset, getSheetObject, getTransformCoord, } from './controllers/utils/component-tools';
|
|
32
32
|
export { enUS, zhCN } from './locale';
|
|
33
33
|
export { AutoFillService, IAutoFillService } from './services/auto-fill/auto-fill.service';
|
|
@@ -190,24 +190,6 @@ declare const _default: {
|
|
|
190
190
|
titleDateTime: string;
|
|
191
191
|
titleNumber: string;
|
|
192
192
|
};
|
|
193
|
-
fontFamily: {
|
|
194
|
-
TimesNewRoman: string;
|
|
195
|
-
Arial: string;
|
|
196
|
-
Tahoma: string;
|
|
197
|
-
Verdana: string;
|
|
198
|
-
MicrosoftYaHei: string;
|
|
199
|
-
SimSun: string;
|
|
200
|
-
SimHei: string;
|
|
201
|
-
Kaiti: string;
|
|
202
|
-
FangSong: string;
|
|
203
|
-
NSimSun: string;
|
|
204
|
-
STXinwei: string;
|
|
205
|
-
STXingkai: string;
|
|
206
|
-
STLiti: string;
|
|
207
|
-
HanaleiFill: string;
|
|
208
|
-
Anton: string;
|
|
209
|
-
Pacifico: string;
|
|
210
|
-
};
|
|
211
193
|
print: {
|
|
212
194
|
normalBtn: string;
|
|
213
195
|
layoutBtn: string;
|
|
@@ -283,6 +265,8 @@ declare const _default: {
|
|
|
283
265
|
title: string;
|
|
284
266
|
cancel: string;
|
|
285
267
|
confirm: string;
|
|
268
|
+
waring: string;
|
|
269
|
+
dismantleMergeCellWaring: string;
|
|
286
270
|
};
|
|
287
271
|
};
|
|
288
272
|
textWrap: {
|
|
@@ -418,6 +402,10 @@ declare const _default: {
|
|
|
418
402
|
freezeRow: string;
|
|
419
403
|
cancelFreeze: string;
|
|
420
404
|
zenEditor: string;
|
|
405
|
+
deleteAllRowsAlert: string;
|
|
406
|
+
deleteAllColumnsAlert: string;
|
|
407
|
+
hideAllRowsAlert: string;
|
|
408
|
+
hideAllColumnsAlert: string;
|
|
421
409
|
};
|
|
422
410
|
info: {
|
|
423
411
|
tooltip: string;
|
|
@@ -443,6 +431,7 @@ declare const _default: {
|
|
|
443
431
|
tipRowHeightLimit: string;
|
|
444
432
|
tipColumnWidthLimit: string;
|
|
445
433
|
pageInfoFull: string;
|
|
434
|
+
problem: string;
|
|
446
435
|
};
|
|
447
436
|
clipboard: {
|
|
448
437
|
paste: {
|
|
@@ -190,24 +190,6 @@ declare const _default: {
|
|
|
190
190
|
titleDateTime: string;
|
|
191
191
|
titleNumber: string;
|
|
192
192
|
};
|
|
193
|
-
fontFamily: {
|
|
194
|
-
TimesNewRoman: string;
|
|
195
|
-
Arial: string;
|
|
196
|
-
Tahoma: string;
|
|
197
|
-
Verdana: string;
|
|
198
|
-
MicrosoftYaHei: string;
|
|
199
|
-
SimSun: string;
|
|
200
|
-
SimHei: string;
|
|
201
|
-
Kaiti: string;
|
|
202
|
-
FangSong: string;
|
|
203
|
-
NSimSun: string;
|
|
204
|
-
STXinwei: string;
|
|
205
|
-
STXingkai: string;
|
|
206
|
-
STLiti: string;
|
|
207
|
-
HanaleiFill: string;
|
|
208
|
-
Anton: string;
|
|
209
|
-
Pacifico: string;
|
|
210
|
-
};
|
|
211
193
|
print: {
|
|
212
194
|
normalBtn: string;
|
|
213
195
|
layoutBtn: string;
|
|
@@ -275,6 +257,8 @@ declare const _default: {
|
|
|
275
257
|
title: string;
|
|
276
258
|
cancel: string;
|
|
277
259
|
confirm: string;
|
|
260
|
+
waring: string;
|
|
261
|
+
dismantleMergeCellWaring: string;
|
|
278
262
|
};
|
|
279
263
|
};
|
|
280
264
|
textWrap: {
|
|
@@ -410,6 +394,10 @@ declare const _default: {
|
|
|
410
394
|
freezeRow: string;
|
|
411
395
|
cancelFreeze: string;
|
|
412
396
|
zenEditor: string;
|
|
397
|
+
deleteAllRowsAlert: string;
|
|
398
|
+
deleteAllColumnsAlert: string;
|
|
399
|
+
hideAllRowsAlert: string;
|
|
400
|
+
hideAllColumnsAlert: string;
|
|
413
401
|
};
|
|
414
402
|
info: {
|
|
415
403
|
tooltip: string;
|
|
@@ -435,6 +423,7 @@ declare const _default: {
|
|
|
435
423
|
tipRowHeightLimit: string;
|
|
436
424
|
tipColumnWidthLimit: string;
|
|
437
425
|
pageInfoFull: string;
|
|
426
|
+
problem: string;
|
|
438
427
|
};
|
|
439
428
|
clipboard: {
|
|
440
429
|
paste: {
|
|
@@ -21,3 +21,4 @@ export declare const chnNumberRule: IAutoFillRule;
|
|
|
21
21
|
export declare const chnWeek2Rule: IAutoFillRule;
|
|
22
22
|
export declare const chnWeek3Rule: IAutoFillRule;
|
|
23
23
|
export declare const loopSeriesRule: IAutoFillRule;
|
|
24
|
+
export declare function reverseIfNeed<T>(data: T[], reverse: boolean): T[];
|
|
@@ -86,7 +86,7 @@ export declare function getDataIndex(csLen: number, asLen: number, indexArr: num
|
|
|
86
86
|
export declare function fillCopy(data: Array<Nullable<ICellData>>, len: number): {
|
|
87
87
|
p: import("@univerjs/core").IDocumentData | null;
|
|
88
88
|
s: string | import("@univerjs/core").IStyleData | null;
|
|
89
|
-
v: import("@univerjs/core").
|
|
89
|
+
v: import("@univerjs/core").CellValue | null;
|
|
90
90
|
t: import("@univerjs/core").CellValueType | null;
|
|
91
91
|
f: string | null;
|
|
92
92
|
si: string | null;
|
|
@@ -97,7 +97,7 @@ export declare function fillCopyStyles(data: Array<Nullable<ICellData>>, len: nu
|
|
|
97
97
|
export declare function isEqualRatio(arr: number[]): boolean;
|
|
98
98
|
export declare function getXArr(len: number): number[];
|
|
99
99
|
export declare function fillSeries(data: Array<Nullable<ICellData>>, len: number, direction: Direction): ICellData[];
|
|
100
|
-
export declare function forecast(x: number, yArr: number[], xArr: number[]): number;
|
|
100
|
+
export declare function forecast(x: number, yArr: number[], xArr: number[], forward?: boolean): number;
|
|
101
101
|
export declare function fillExtendNumber(data: Array<Nullable<ICellData>>, len: number, step: number): ICellData[];
|
|
102
102
|
export declare function fillOnlyFormat(data: Array<Nullable<ICellData>>, len: number): ICellData[];
|
|
103
103
|
export declare function fillChnWeek(data: Array<Nullable<ICellData>>, len: number, step: number, weekType?: number): ICellData[];
|
|
@@ -13,14 +13,14 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
import type { IRange, ObjectMatrix } from '@univerjs/core';
|
|
16
|
+
import type { IRange, Nullable, ObjectMatrix } from '@univerjs/core';
|
|
17
17
|
import type { COPY_TYPE, ICellDataWithSpanInfo } from './type';
|
|
18
18
|
export interface ICopyContentCacheData {
|
|
19
19
|
subUnitId: string;
|
|
20
20
|
unitId: string;
|
|
21
21
|
range: IRange;
|
|
22
22
|
copyType: COPY_TYPE;
|
|
23
|
-
matrix: ObjectMatrix<ICellDataWithSpanInfo
|
|
23
|
+
matrix: Nullable<ObjectMatrix<ICellDataWithSpanInfo>>;
|
|
24
24
|
}
|
|
25
25
|
export declare function genId(): string;
|
|
26
26
|
export declare function extractId(html: string): string | null;
|
|
@@ -0,0 +1,45 @@
|
|
|
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 { ISelection, ITextRangeParam, Nullable } from '@univerjs/core';
|
|
17
|
+
import { IUniverInstanceService, LocaleService } from '@univerjs/core';
|
|
18
|
+
import type { KeyCode } from '@univerjs/ui';
|
|
19
|
+
import type { IDisposable } from '@wendellhu/redi';
|
|
20
|
+
export interface IShortcutExperienceSearch {
|
|
21
|
+
unitId: string;
|
|
22
|
+
sheetId: string;
|
|
23
|
+
keycode: KeyCode;
|
|
24
|
+
}
|
|
25
|
+
export interface IShortcutExperienceParam extends IShortcutExperienceSearch {
|
|
26
|
+
selection?: ISelection;
|
|
27
|
+
textSelection?: ITextRangeParam;
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* This service is prepared for shortcut experience optimization,
|
|
31
|
+
* including the combined use of enter and tab, the highlighting experience of formulas in the editor, and so on.
|
|
32
|
+
*/
|
|
33
|
+
export declare class ShortcutExperienceService implements IDisposable {
|
|
34
|
+
private readonly _currentUniverService;
|
|
35
|
+
private readonly _localeService;
|
|
36
|
+
private _current;
|
|
37
|
+
private _shortcutParam;
|
|
38
|
+
constructor(_currentUniverService: IUniverInstanceService, _localeService: LocaleService);
|
|
39
|
+
dispose(): void;
|
|
40
|
+
getCurrentBySearch(searchParm: Nullable<IShortcutExperienceSearch>): Nullable<IShortcutExperienceParam>;
|
|
41
|
+
getCurrent(): Nullable<IShortcutExperienceParam>;
|
|
42
|
+
addOrUpdate(insertParam: IShortcutExperienceParam): Nullable<IShortcutExperienceParam>;
|
|
43
|
+
remove(searchParm: Nullable<IShortcutExperienceSearch>): Nullable<IShortcutExperienceParam>;
|
|
44
|
+
private _getCurrentBySearch;
|
|
45
|
+
}
|
|
@@ -29,7 +29,7 @@ export interface SlideTabBarConfig {
|
|
|
29
29
|
currentIndex: number;
|
|
30
30
|
onSlideEnd: (event: MouseEvent, compareIndex: number) => void;
|
|
31
31
|
onChangeName: (id: string, name: string) => void;
|
|
32
|
-
onChangeTab: (event:
|
|
32
|
+
onChangeTab: (event: MouseEvent, id: string) => void;
|
|
33
33
|
onScroll: (state: IScrollState) => void;
|
|
34
34
|
onNameCheckAlert: (text: string) => boolean;
|
|
35
35
|
}
|
|
@@ -53,6 +53,8 @@ export declare class SlideTabItem {
|
|
|
53
53
|
static make(nodeList: NodeList, slideTabBar: SlideTabBar): SlideTabItem[];
|
|
54
54
|
getSlideTabItem(): HTMLElement;
|
|
55
55
|
getEditor(): HTMLSpanElement | null;
|
|
56
|
+
focus(): void;
|
|
57
|
+
selectAll(): void;
|
|
56
58
|
isEditMode(): boolean;
|
|
57
59
|
classList(): DOMTokenList;
|
|
58
60
|
translateX(x: number): 1 | 0 | -1;
|