@titaui/pc 1.11.4-1 → 1.11.4-12
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/lib/components/avatar/text-avatar/index.css +7 -0
- package/lib/components/avatar/text-avatar/index.js +32 -7
- package/lib/components/button/rect-btn/index.js +7 -7
- package/lib/components/change-okr-modal/Item.js +15 -15
- package/lib/components/communication/index.js +30 -29
- package/lib/components/date-picker/BodyItem.js +3 -3
- package/lib/components/date-picker/CalendarHeader.js +3 -3
- package/lib/components/delete-confirm-pop/ConfirmPop.js +3 -3
- package/lib/components/drawer/index.js +7 -6
- package/lib/components/dynamic/constant.js +13 -6
- package/lib/components/dynamic/dynamic-item/dynamic-ai-dialy/dynamic-footer.js +243 -0
- package/lib/components/dynamic/dynamic-item/dynamic-ai-dialy/index.js +6 -2
- package/lib/components/dynamic/dynamic-item/dynamic-interview/index.css +22 -7
- package/lib/components/dynamic/dynamic-item/dynamic-interview/index.js +6 -7
- package/lib/components/dynamic/dynamic-item/dynamic-interview/interview-content.js +19 -7
- package/lib/components/dynamic/dynamic-item/dynamic-interview-share/img/wifi.svg +24 -0
- package/lib/components/dynamic/dynamic-item/dynamic-interview-share/index.css +61 -0
- package/{es/pages/group-management/page-view/loading → lib/components/dynamic/dynamic-item/dynamic-interview-share}/index.js +40 -11
- package/lib/components/dynamic/dynamic-item/dynamic-interview-share/interview-content.js +69 -0
- package/lib/components/dynamic/dynamic-item/dynamic-kr/index.js +6 -6
- package/lib/components/dynamic/dynamic-item/dynamic-milestone/index.js +7 -7
- package/lib/components/dynamic/dynamic-item/dynamic-progress/index.js +11 -11
- package/lib/components/dynamic/dynamic-item/dynamic-reply/index.js +14 -14
- package/lib/components/dynamic/dynamic-item/dynamic-task/index.js +10 -10
- package/lib/components/dynamic/dynamic-item/index.js +34 -13
- package/lib/components/dynamic/dynamic-list/index.js +5 -13
- package/lib/components/e-priority/index.js +18 -12
- package/lib/components/eReport/eReportLists/reportList.js +3 -3
- package/lib/components/eReport/eReportShare/index.js +11 -11
- package/lib/components/emotions-selector/selector-pop.js +3 -3
- package/lib/components/ereport-list/index.js +3 -3
- package/lib/components/file-list/components/single-file/index.js +11 -11
- package/lib/components/form/form-fields/date/index.js +15 -11
- package/lib/components/form/form-fields/input/index.js +10 -10
- package/lib/components/form/form-fields/user/index.css +22 -2
- package/lib/components/form/form-fields/user/index.js +18 -8
- package/lib/components/form/form-fields/user/user-input.js +15 -6
- package/lib/components/icon-button-list/index.css +2 -57
- package/lib/components/icon-button-list/index.js +10 -7
- package/lib/components/img-viewer/index.css +10 -3
- package/lib/components/img-viewer/index.js +57 -18
- package/lib/components/mblog/components/MblogAction.js +3 -3
- package/lib/components/mblog/index.js +31 -30
- package/lib/components/menus/components/menu-tree/images/interview-menu/my-interview.svg +16 -0
- package/lib/components/menus/components/menu-tree/images/interview-menu/template.svg +16 -0
- package/lib/components/menus/components/menu-tree/images/interview-menu/todo.svg +16 -0
- package/lib/components/menus/components/menu-tree/index.css +4 -2
- package/lib/components/menus/components/menu-tree/tree-node/index.css +85 -1
- package/lib/components/menus/export-modules/interview-menus/constant.js +12 -12
- package/lib/components/menus/export-modules/interview-menus/index.css +7 -0
- package/lib/components/menus/export-modules/interview-menus/index.js +4 -2
- package/lib/components/nav-top/components/menu/index.js +14 -14
- package/lib/components/nav-top/components/user-message/components/inform/inform-item.js +25 -19
- package/lib/components/nav-top/components/user-message/components/remind/remind-item.js +48 -10
- package/lib/components/nav-top/components/user-message/constant.js +1 -0
- package/lib/components/nav-top/components/user-message/hrMessage.js +22 -19
- package/lib/components/nav-top/components/user-message/index.js +23 -20
- package/lib/components/nav-top/request.apis.js +3 -1
- package/lib/components/okr-detail/components/okr-tree/tree-node/e-node/e-priority-dropdown.js +7 -7
- package/lib/components/okr-detail/components/okr-tree/tree-node/kr-node/kr-score-editor/edit-pop.js +3 -3
- package/lib/components/okr-detail/detail-header/actions.js +62 -66
- package/lib/components/okr-detail/detail-header/index.css +2 -2
- package/lib/components/okr-detail/detail-header/index.js +205 -194
- package/lib/components/okr-detail/index.js +21 -19
- package/lib/components/okr-flow/child-node/index.css +67 -21
- package/lib/components/okr-flow/child-node/work-node.js +61 -24
- package/lib/components/okr-flow/empty/index.css +8 -1
- package/lib/components/okr-flow/export-modal/index.js +42 -18
- package/lib/components/okr-flow/export-modules/okr-search-panel/index.css +3 -1
- package/lib/components/okr-flow/export-modules/okr-search-panel/index.js +30 -24
- package/lib/components/okr-flow/images/loading-light.gif +0 -0
- package/lib/components/okr-flow/okr-map/index.js +43 -22
- package/lib/components/okr-flow/request-apis.js +15 -8
- package/lib/components/okr-flow/root-node/index.css +2 -2
- package/lib/components/okr-flow/root-node/index.js +26 -25
- package/lib/components/okr-flow/utils/index.js +45 -29
- package/lib/components/okr-flow/utils/tree-handler.js +29 -18
- package/lib/components/okr-review/components/ReviewItem/index.js +3 -3
- package/lib/components/okr-review/components/confirm-pop/ConfirmPop.js +3 -3
- package/lib/components/okrcase-library/index.css +6 -4
- package/lib/components/okrcase-library/okrcases-components/submitOkr-dialog.js +36 -30
- package/lib/components/pagination/index.css +3 -3
- package/lib/components/pagination/select.css +58 -23
- package/lib/components/period-selector/index.css +9 -3
- package/lib/components/period-selector/index.js +14 -11
- package/lib/components/picker/components/panels/date-panel/date-body.js +21 -19
- package/lib/components/picker/components/panels/date-panel/date-head.js +29 -8
- package/lib/components/picker/components/panels/month-panel/month-body.js +6 -4
- package/lib/components/picker/components/picker-trigger/index.css +15 -0
- package/lib/components/picker/components/picker-trigger/index.js +8 -8
- package/lib/components/popup/index.js +4 -4
- package/lib/components/radio/index.css +9 -9
- package/lib/components/range-selector-pop/RangeSelectorPop.js +3 -3
- package/lib/components/rich-editor/models/schema.js +6 -6
- package/lib/components/rich-editor/plugins/block/block-quote/index.js +8 -8
- package/lib/components/rich-editor/plugins/block/heading/index.js +8 -8
- package/lib/components/rich-editor/plugins/block/lists/index.js +14 -14
- package/lib/components/rich-editor/plugins/block/paragraph/index.js +5 -5
- package/lib/components/rich-editor/plugins/core/index.js +4 -4
- package/lib/components/rich-editor/plugins/extension/alignment/index.js +5 -5
- package/lib/components/rich-editor/plugins/extension/placeholder/index.js +4 -4
- package/lib/components/rich-editor/plugins/inline/color/index.js +11 -11
- package/lib/components/rich-editor/plugins/inline/delete-line/index.js +8 -8
- package/lib/components/rich-editor/plugins/inline/em/index.js +5 -5
- package/lib/components/rich-editor/plugins/inline/link/index.js +8 -8
- package/lib/components/rich-editor/plugins/inline/strong/index.js +8 -8
- package/lib/components/rich-editor/plugins/inline/under-line/index.js +8 -8
- package/lib/components/rich-editor/react/uiProvider.js +3 -3
- package/lib/components/rich-editor/ui/Popup/index.js +3 -3
- package/lib/components/scroll-container/index.js +423 -0
- package/lib/components/scroll-container/style.css +35 -0
- package/lib/components/scrollbar/scroll-mask/index.js +1 -1
- package/lib/components/select/Option.js +3 -3
- package/lib/components/superset-charts/components/chart/index.js +1 -1
- package/lib/components/superset-charts/utils/axios.js +5 -13
- package/{es/pages/group-management/page-view/group-empty.js → lib/components/survey-model/contact.js} +54 -27
- package/lib/components/survey-model/index.css +141 -0
- package/lib/components/survey-model/index.js +265 -0
- package/lib/components/survey-model/instance.js +86 -0
- package/lib/components/survey-model/request-api.js +80 -0
- package/lib/components/task-tree/helper.js +61 -0
- package/lib/components/task-tree/images/P1.svg +15 -0
- package/lib/components/task-tree/images/P2.svg +15 -0
- package/lib/components/task-tree/images/P3.svg +15 -0
- package/lib/components/task-tree/images/P4.svg +15 -0
- package/lib/components/task-tree/images/P5.svg +15 -0
- package/lib/components/task-tree/images/arrow.svg +9 -0
- package/lib/components/task-tree/images/empty-131.png +0 -0
- package/lib/components/task-tree/images/followed.svg +33 -0
- package/lib/components/task-tree/images/nice.svg +108 -0
- package/lib/components/task-tree/images/struc12.png +0 -0
- package/lib/components/task-tree/images/struc2.png +0 -0
- package/lib/components/task-tree/images/xialat-s.svg +13 -0
- package/lib/components/task-tree/index.js +22 -0
- package/lib/components/task-tree/mock.js +944 -0
- package/{es/components/okr-detail/e-list → lib/components/task-tree}/precls.js +1 -1
- package/lib/components/task-tree/request-apis.js +88 -0
- package/lib/components/task-tree/task-item-node/constant.js +45 -0
- package/{es/components/okr-detail/components/okr-tree/tree-node/default-node.js → lib/components/task-tree/task-item-node/e-empty.js} +13 -6
- package/{es/components/okr-detail/components/okr-tree/tree-node/e-node → lib/components/task-tree/task-item-node}/e-project.js +63 -51
- package/{es/components/e-status-dropdown/index.js → lib/components/task-tree/task-item-node/e-status-dropdown.js} +13 -13
- package/{es/components/okr-detail/components/okr-tree/tree-node/e-node/e-task-level2.js → lib/components/task-tree/task-item-node/e-task.js} +138 -124
- package/{es/components/okr-detail/components/okr-tree/tree-node → lib/components/task-tree/task-item-node}/get-process-color.js +3 -3
- package/lib/components/task-tree/task-item-node/index.css +289 -0
- package/lib/components/task-tree/task-item-node/task-node-render.js +43 -0
- package/lib/components/task-tree/task-tree.css +16 -0
- package/{es/components/okr-detail/components/okr-tree/index.js → lib/components/task-tree/task-tree.js} +17 -16
- package/lib/components/time-picker/index.css +6 -0
- package/lib/components/time-picker/time-picker.js +45 -33
- package/lib/components/tita-chart/errorBoundary/index.js +3 -3
- package/lib/components/user-selector/select-tree/tree-nodes/tree-person-node/index.css +1 -0
- package/lib/components/wechat-btn/index.css +14 -0
- package/lib/components/wechat-btn/index.js +338 -0
- package/lib/components-v1/animate/AnimateChild.js +3 -3
- package/lib/components-v1/avatar/index.js +3 -3
- package/lib/components-v1/dropDownSelector/StatelessDropdown.js +3 -3
- package/lib/components-v1/progress/CircleProgress.js +3 -3
- package/lib/components-v1/radio/radio.js +3 -3
- package/lib/components-v1/radio/style/index.css +8 -8
- package/lib/components-v1/select/Option.js +3 -3
- package/lib/components-v1/userSelector/UserSelectorPop.js +3 -3
- package/lib/components-v1/userSelector/components/MultiMode/index.js +3 -3
- package/lib/components-v1/userSelector/components/UserItem.js +3 -3
- package/lib/index.js +99 -91
- package/lib/pages/okr-map/export-modules/okr-map/header/index.css +7 -2
- package/lib/pages/okr-map/export-modules/okr-map/header/index.js +73 -34
- package/lib/pages/okr-map/export-modules/okr-map/okr-map.js +65 -42
- package/lib/pages/okr-map/export-modules/share-okr-page/header/index.css +26 -14
- package/lib/pages/okr-map/export-modules/share-okr-page/header/index.js +58 -13
- package/lib/pages/okr-map/export-modules/share-okr-page/share-okr-map.js +28 -20
- package/lib/pages/okr-map/number-select/index.css +12 -9
- package/lib/pages/okr-map/number-select/index.js +3 -3
- package/lib/utils/auth.js +65 -8
- package/lib/utils/bs-global.js +18 -6
- package/lib/utils/open-data.js +63 -43
- package/package.json +6 -2
- package/.eslintignore +0 -3
- package/.eslintrc.js +0 -223
- package/.husky/pre-commit +0 -4
- package/.prettierignore +0 -31
- package/.prettierrc.js +0 -90
- package/.vscode/settings.json +0 -5
- package/es/components/cascader/time.js +0 -31
- package/es/components/common-share/request-apis.js +0 -56
- package/es/components/confidence/heart.js +0 -66
- package/es/components/create-okr-modal/fields/index.js +0 -17
- package/es/components/create-okr-modal/utils/getCreateOkrSurpassPercent.js +0 -154
- package/es/components/date-picker/BodyItem.js +0 -121
- package/es/components/date-picker/CalendarBody.js +0 -157
- package/es/components/date-picker/CalendarHeader.js +0 -187
- package/es/components/date-picker/index.js +0 -157
- package/es/components/date-range-picker/index.js +0 -210
- package/es/components/dialog/index.js +0 -119
- package/es/components/dialog-confirm/index.js +0 -154
- package/es/components/drop-selector/icon-item.js +0 -40
- package/es/components/drop-selector/index.js +0 -179
- package/es/components/dynamic/dynamic-like-ranking/mock.js +0 -84
- package/es/components/dynamic/dynamic-liking/mock.js +0 -83
- package/es/components/dynamic/dynamic-topping/request-api.js +0 -36
- package/es/components/e-priority/index.js +0 -88
- package/es/components/grid-layout/commen-components/index.js +0 -73
- package/es/components/grid-layout/image/could.js +0 -8
- package/es/components/grid-layout/image/lv.js +0 -8
- package/es/components/grid-layout/image/tita-mask.js +0 -8
- package/es/components/help-card/request-api.js +0 -35
- package/es/components/icon-button-list/index.js +0 -65
- package/es/components/menus/context.js +0 -18
- package/es/components/menus/precls.js +0 -8
- package/es/components/okr-detail/auth.js +0 -197
- package/es/components/okr-detail/components/ao-nice/index.js +0 -245
- package/es/components/okr-detail/components/block-line/index.js +0 -20
- package/es/components/okr-detail/components/header/index.js +0 -211
- package/es/components/okr-detail/components/icon-text/index.js +0 -116
- package/es/components/okr-detail/components/okr-tree/precls.js +0 -8
- package/es/components/okr-detail/components/okr-tree/tree-node/e-node/e-priority-dropdown.js +0 -88
- package/es/components/okr-detail/components/okr-tree/tree-node/e-node/e-status-dropdown.js +0 -98
- package/es/components/okr-detail/components/okr-tree/tree-node/index.js +0 -90
- package/es/components/okr-detail/components/okr-tree/tree-node/kr-node/get-process-color.js +0 -46
- package/es/components/okr-detail/components/okr-tree/tree-node/kr-node/index.js +0 -421
- package/es/components/okr-detail/components/okr-tree/tree-node/kr-node/kr-score-editor/index.js +0 -54
- package/es/components/okr-detail/components/okr-tree/tree-node/kr-node/kr-score-editor/style.js +0 -62
- package/es/components/okr-detail/components/okr-tree/tree-node/kr-node/range-picker-pop.js +0 -94
- package/es/components/okr-detail/components/okr-tree/tree-node/kr-parent-node/index.js +0 -273
- package/es/components/okr-detail/components/okr-tree/tree-node/o-child-node/index.js +0 -207
- package/es/components/okr-detail/components/okr-tree/tree-node/o-parent-node/index.js +0 -236
- package/es/components/okr-detail/components/padding-layout.js +0 -22
- package/es/components/okr-detail/components/tab-panel-content/index.js +0 -27
- package/es/components/okr-detail/context.js +0 -30
- package/es/components/okr-detail/e-list/index.js +0 -243
- package/es/components/okr-detail/e-list/search-form/fields/e-order.js +0 -172
- package/es/components/okr-detail/e-list/search-form/fields/e-status.js +0 -99
- package/es/components/okr-detail/e-list/search-form/fields/e-user.js +0 -49
- package/es/components/okr-detail/e-list/search-form/index.js +0 -143
- package/es/components/okr-detail/error-page/index.js +0 -33
- package/es/components/okr-detail/index.js +0 -428
- package/es/components/okr-detail/loading/index.js +0 -28
- package/es/components/okr-detail/okr-list/add-parent-okr.js +0 -37
- package/es/components/okr-detail/okr-list/create-kr-item/heart.js +0 -38
- package/es/components/okr-detail/okr-list/drag-order-kr.js +0 -62
- package/es/components/okr-detail/okr-list/empty/index.js +0 -48
- package/es/components/okr-detail/okr-list/index.js +0 -524
- package/es/components/okr-detail/okr-list/warp-parent-okr.js +0 -21
- package/es/components/okr-detail/store.js +0 -1
- package/es/components/okr-flow/child-node/fields/creator.js +0 -175
- package/es/components/okr-flow/child-node/fields/okrClassify.js +0 -31
- package/es/components/okr-flow/child-node/fields/okrType.js +0 -21
- package/es/components/okr-flow/child-node/helper.js +0 -35
- package/es/components/okr-flow/child-node/index.js +0 -110
- package/es/components/okr-flow/child-node/kr-node.js +0 -75
- package/es/components/okr-flow/child-node/work-node.js +0 -242
- package/es/components/okr-flow/context.js +0 -14
- package/es/components/okr-flow/empty/index.js +0 -29
- package/es/components/okr-flow/export-modules/okr-search-panel/index.js +0 -394
- package/es/components/okr-flow/index.js +0 -24
- package/es/components/okr-flow/mini-map/index.js +0 -112
- package/es/components/okr-flow/mini-map/map.js +0 -145
- package/es/components/okr-flow/mini-map/mini-node.js +0 -57
- package/es/components/okr-flow/mini-map/utils.js +0 -79
- package/es/components/okr-flow/okr-map/index.js +0 -192
- package/es/components/okr-flow/open-data/index.js +0 -115
- package/es/components/okr-flow/precls.js +0 -8
- package/es/components/okr-flow/request-apis.js +0 -118
- package/es/components/okr-flow/root-node/index.js +0 -229
- package/es/components/okr-flow/utils/config.js +0 -18
- package/es/components/okr-flow/utils/helper.js +0 -36
- package/es/components/okr-flow/utils/index.js +0 -66
- package/es/components/okr-flow/utils/tree-handler.js +0 -323
- package/es/components/okr-progress-modal/helper.js +0 -156
- package/es/components/okr-progress-modal/request-apis.js +0 -34
- package/es/components/okr-share/request-apis.js +0 -56
- package/es/components/okrcase-library/server/network.js +0 -407
- package/es/components/pagination/locale/en_US.js +0 -22
- package/es/components/pagination/locale/zh_CN.js +0 -22
- package/es/components/point-demo/drop-down-box/index.js +0 -159
- package/es/components/point-demo/index.js +0 -533
- package/es/components/point-demo/input/index.js +0 -176
- package/es/components/point-demo/point-demo.js +0 -75
- package/es/components/point-demo/popup/index.js +0 -113
- package/es/components/point-demo/popup/placement.js +0 -44
- package/es/components/range-picker-pop/index.js +0 -273
- package/es/components/scrollbar/simplebar/helpers.js +0 -59
- package/es/components/scrollbar/simplebar/index.js +0 -91
- package/es/components/scrollbar/simplebar/scrollbar-width.js +0 -47
- package/es/components/scrollbar/simplebar/simplebar.js +0 -852
- package/es/components/scrollbar/simplebar-react.js +0 -163
- package/es/components/search-dropdown/index.js +0 -40
- package/es/components/search-input/index.js +0 -126
- package/es/components/select/Option.js +0 -94
- package/es/components/select/index.js +0 -330
- package/es/components/selector-input/debounce.js +0 -36
- package/es/components/selector-input/index.js +0 -109
- package/es/components/slider-input/index.js +0 -119
- package/es/components/switch/index.js +0 -39
- package/es/components/table/index.js +0 -275
- package/es/components/tabs/index.js +0 -63
- package/es/components/task-relation-modal/tree-node/index.js +0 -58
- package/es/components/tita-chart/charts/img/could.js +0 -8
- package/es/components/tooltip/error-tip.js +0 -24
- package/es/components/tooltip/index.js +0 -21
- package/es/components/tree/index.js +0 -79
- package/es/components/tree/precls.js +0 -8
- package/es/components/upvote/request-apis.js +0 -45
- package/es/components/user-selector/action-btns/btn-cancel.js +0 -21
- package/es/components/user-selector/action-btns/btn-ok.js +0 -21
- package/es/components/user-selector/action-btns/index.js +0 -27
- package/es/components/user-selector/context.js +0 -18
- package/es/components/user-selector/empty/group.js +0 -55
- package/es/components/user-selector/empty/index.js +0 -28
- package/es/components/user-selector/export-modules/depart-search-selector/result-part.js +0 -41
- package/es/components/user-selector/export-modules/group-selector/index.js +0 -170
- package/es/components/user-selector/export-modules/group-selector/searched-panel.js +0 -68
- package/es/components/user-selector/export-modules/multiple-user-selector--bak/index.js +0 -246
- package/es/components/user-selector/index.js +0 -25
- package/es/components/user-selector/layout/index.js +0 -25
- package/es/components/user-selector/loading/index.js +0 -18
- package/es/components/user-selector/request-apis.js +0 -180
- package/es/components/user-selector/searched-panel/index.js +0 -139
- package/es/components/user-selector/searched-panel/result-part.js +0 -43
- package/es/components/user-selector/select-tree/selected-tree/index.js +0 -91
- package/es/components/user-selector/select-tree/tree-nodes/tree-depart-node/index.js +0 -48
- package/es/components/user-selector/select-tree/tree-nodes/tree-duties-node/index.js +0 -27
- package/es/components/user-selector/select-tree/tree-nodes/tree-group-node/index.js +0 -57
- package/es/components/user-selector/select-tree/tree-nodes/tree-person-node/index.js +0 -93
- package/es/components/user-selector/utils.js +0 -139
- package/es/components/viewer/ImageListRender.js +0 -143
- package/es/components/viewer/index.js +0 -168
- package/es/components/word-cloud/index.js +0 -109
- package/es/components/word-cloud/request-apis.js +0 -26
- package/es/components-v1/animate/AnimateChild.js +0 -76
- package/es/components-v1/animate/animate.js +0 -148
- package/es/components-v1/animate/index.js +0 -13
- package/es/components-v1/dom/index.js +0 -30
- package/es/components-v1/placement/index.js +0 -13
- package/es/components-v1/placement/placement.js +0 -111
- package/es/components-v1/placement/placementInner.js +0 -139
- package/es/components-v1/pop/Pop.js +0 -246
- package/es/components-v1/pop/PopInner.js +0 -163
- package/es/components-v1/pop/index.js +0 -13
- package/es/components-v1/progress/CircleProgress.js +0 -152
- package/es/components-v1/progress/LineProgress.js +0 -83
- package/es/components-v1/progress/index.js +0 -80
- package/es/components-v1/select/Option.js +0 -94
- package/es/components-v1/select/index.js +0 -330
- package/es/components-v1/utils/animate/animate.js +0 -103
- package/es/components-v1/utils/animate/event.js +0 -79
- package/es/components-v1/utils/dom/index.js +0 -30
- package/es/components-v1/utils/placement/autoAdjustPlacement.js +0 -93
- package/es/components-v1/utils/placement/getContainerVisibleArea.js +0 -22
- package/es/components-v1/utils/placement/getExpectPlacement.js +0 -49
- package/es/components-v1/utils/placement/getPlacementInContainer.js +0 -26
- package/es/components-v1/utils/placement/placement.js +0 -76
- package/es/index.js +0 -777
- package/es/pages/appointment-demo/drop-down-box/index.js +0 -159
- package/es/pages/appointment-demo/index.js +0 -649
- package/es/pages/appointment-demo/input/index.js +0 -176
- package/es/pages/appointment-demo/popup/index.js +0 -113
- package/es/pages/appointment-demo/popup/placement.js +0 -44
- package/es/pages/group-management/components/checkbox/index.js +0 -28
- package/es/pages/group-management/components/input-form/index.js +0 -174
- package/es/pages/group-management/components/radio/index.js +0 -21
- package/es/pages/group-management/components/table/index.js +0 -174
- package/es/pages/group-management/groupInterface.js +0 -293
- package/es/pages/group-management/index.js +0 -13
- package/es/pages/group-management/page-view/empty.js +0 -111
- package/es/pages/group-management/page-view/importGroupStaff/index.js +0 -208
- package/es/pages/group-management/page-view/index.js +0 -412
- package/es/pages/group-management/table/index.js +0 -104
- package/es/pages/group-management/tree/add-group-dialog/index.js +0 -153
- package/es/pages/group-management/tree/delete-group-dialog/index.js +0 -82
- package/es/pages/group-management/tree/edit-group-dialog/index.js +0 -155
- package/es/pages/group-management/tree/group-form/index.js +0 -207
- package/es/pages/group-management/tree/index.js +0 -168
- package/es/pages/group-management/tree/operation-panel.js +0 -41
- package/es/pages/group-management/tree/trigger-render.js +0 -99
- package/es/pages/like-ranking/mock.js +0 -366
- package/es/pages/okr-map/export-modules/index.js +0 -1
- package/es/pages/okr-map/export-modules/okr-map/header/index.js +0 -182
- package/es/pages/okr-map/export-modules/okr-map/header/show-kr-confirm.js +0 -47
- package/es/pages/okr-map/export-modules/okr-map/okr-map.js +0 -497
- package/es/pages/okr-map/export-modules/share-okr-page/header/index.js +0 -69
- package/es/pages/okr-map/export-modules/share-okr-page/share-okr-map.js +0 -168
- package/es/pages/okr-map/hooks/useStorage.js +0 -96
- package/es/pages/okr-map/index.js +0 -18
- package/es/pages/okr-map/level2-search/depart.js +0 -53
- package/es/pages/okr-map/level2-search/group.js +0 -69
- package/es/pages/okr-map/level2-search/index.js +0 -51
- package/es/pages/okr-map/level2-search/level2-input.js +0 -46
- package/es/pages/okr-map/level2-search/user.js +0 -54
- package/es/pages/okr-map/no-okr/index.js +0 -24
- package/es/pages/okr-map/number-select/index.js +0 -81
- package/es/pages/okr-map/open-data/index.js +0 -115
- package/es/pages/okr-map/precls.js +0 -8
- package/es/pages/okr-map/request-apis.js +0 -76
- package/es/pages/okr-map/share-dialog/index.js +0 -122
- package/es/pages/okr-map/unsupport-ie/index.js +0 -83
- package/es/pages/okr-map/utils.js +0 -51
- package/es/utils/auth.js +0 -294
- package/es/utils/bs-global.js +0 -114
- package/es/utils/local-storage.js +0 -42
- package/es/utils/mblog.js +0 -33
- package/es/utils/mock-bsglobal.js +0 -1837
- package/es/utils/open-data.js +0 -341
- package/es/utils/request-v1.js +0 -115
- package/es/utils/request.js +0 -183
- package/es/utils/tools.js +0 -286
- package/yarn-error.log +0 -21252
|
@@ -1,246 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
|
-
|
|
5
|
-
Object.defineProperty(exports, "__esModule", {
|
|
6
|
-
value: true
|
|
7
|
-
});
|
|
8
|
-
exports["default"] = void 0;
|
|
9
|
-
|
|
10
|
-
var _react = _interopRequireWildcard(require("react"));
|
|
11
|
-
|
|
12
|
-
var _reactDom = _interopRequireWildcard(require("react-dom"));
|
|
13
|
-
|
|
14
|
-
var _uuid = require("uuid");
|
|
15
|
-
|
|
16
|
-
var _animate = _interopRequireDefault(require("../animate"));
|
|
17
|
-
|
|
18
|
-
var _placement = _interopRequireDefault(require("../placement"));
|
|
19
|
-
|
|
20
|
-
var _PopInner = _interopRequireDefault(require("./PopInner"));
|
|
21
|
-
|
|
22
|
-
require("./index.scss");
|
|
23
|
-
|
|
24
|
-
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
25
|
-
|
|
26
|
-
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
27
|
-
|
|
28
|
-
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
29
|
-
|
|
30
|
-
function _createForOfIteratorHelper(o, allowArrayLike) { var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"]; if (!it) { if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = it.call(o); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it["return"] != null) it["return"](); } finally { if (didErr) throw err; } } }; }
|
|
31
|
-
|
|
32
|
-
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
33
|
-
|
|
34
|
-
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
|
35
|
-
|
|
36
|
-
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
37
|
-
|
|
38
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
39
|
-
|
|
40
|
-
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
41
|
-
|
|
42
|
-
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
43
|
-
|
|
44
|
-
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
45
|
-
|
|
46
|
-
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
47
|
-
|
|
48
|
-
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
|
49
|
-
|
|
50
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
51
|
-
|
|
52
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
53
|
-
|
|
54
|
-
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
55
|
-
|
|
56
|
-
var suspend = /*#__PURE__*/function (_Component) {
|
|
57
|
-
_inherits(suspend, _Component);
|
|
58
|
-
|
|
59
|
-
var _super = _createSuper(suspend);
|
|
60
|
-
|
|
61
|
-
function suspend(props) {
|
|
62
|
-
var _this;
|
|
63
|
-
|
|
64
|
-
_classCallCheck(this, suspend);
|
|
65
|
-
|
|
66
|
-
_this = _super.call(this, props);
|
|
67
|
-
|
|
68
|
-
_this.resetPosition = function () {
|
|
69
|
-
_this.refs.inner.resetPosition();
|
|
70
|
-
};
|
|
71
|
-
|
|
72
|
-
_this.getBindNode = function () {
|
|
73
|
-
return _this.state.bindNode;
|
|
74
|
-
};
|
|
75
|
-
|
|
76
|
-
_this.bindBlurHandle = function () {
|
|
77
|
-
// 给document绑定事件,实现点击弹框以外区域隐藏弹框
|
|
78
|
-
if (_this.blurHandler) return;
|
|
79
|
-
_this.blurHandler = window.document.addEventListener("mousedown", _this.handleBlur);
|
|
80
|
-
};
|
|
81
|
-
|
|
82
|
-
_this.handleBlur = function (e) {
|
|
83
|
-
var _this$props = _this.props,
|
|
84
|
-
shouldHide = _this$props.shouldHide,
|
|
85
|
-
hideing = _this$props.hideing;
|
|
86
|
-
|
|
87
|
-
var el = _this.refs.inner.getEl();
|
|
88
|
-
|
|
89
|
-
if (shouldHide && !shouldHide(e, el)) {
|
|
90
|
-
return;
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
if (!shouldHide) {
|
|
94
|
-
if (el.contains(e.target)) return;
|
|
95
|
-
var popArr = document.querySelectorAll("[data-uid=".concat(_this.popId, "] [data-tita-pop]"));
|
|
96
|
-
|
|
97
|
-
var _iterator = _createForOfIteratorHelper(popArr),
|
|
98
|
-
_step;
|
|
99
|
-
|
|
100
|
-
try {
|
|
101
|
-
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
|
102
|
-
var pcEl = _step.value;
|
|
103
|
-
var popEl = document.querySelector("[data-uid=".concat(pcEl.getAttribute("data-tita-pop"), "]"));
|
|
104
|
-
if (popEl && popEl.contains(e.target)) return;
|
|
105
|
-
}
|
|
106
|
-
} catch (err) {
|
|
107
|
-
_iterator.e(err);
|
|
108
|
-
} finally {
|
|
109
|
-
_iterator.f();
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
var titaPopWrappers = document.getElementsByClassName("titaui-popup");
|
|
114
|
-
|
|
115
|
-
var _iterator2 = _createForOfIteratorHelper(titaPopWrappers),
|
|
116
|
-
_step2;
|
|
117
|
-
|
|
118
|
-
try {
|
|
119
|
-
for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
|
|
120
|
-
var titaPopEl = _step2.value;
|
|
121
|
-
if (titaPopEl && titaPopEl.contains(e.target)) return;
|
|
122
|
-
}
|
|
123
|
-
} catch (err) {
|
|
124
|
-
_iterator2.e(err);
|
|
125
|
-
} finally {
|
|
126
|
-
_iterator2.f();
|
|
127
|
-
}
|
|
128
|
-
|
|
129
|
-
var noShadowPops = document.querySelectorAll(".tita-common-pop-no-shadow");
|
|
130
|
-
|
|
131
|
-
var _iterator3 = _createForOfIteratorHelper(noShadowPops),
|
|
132
|
-
_step3;
|
|
133
|
-
|
|
134
|
-
try {
|
|
135
|
-
for (_iterator3.s(); !(_step3 = _iterator3.n()).done;) {
|
|
136
|
-
var _titaPopEl = _step3.value;
|
|
137
|
-
if (_titaPopEl && _titaPopEl.contains(e.target)) return;
|
|
138
|
-
}
|
|
139
|
-
} catch (err) {
|
|
140
|
-
_iterator3.e(err);
|
|
141
|
-
} finally {
|
|
142
|
-
_iterator3.f();
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
hideing && hideing(e, false);
|
|
146
|
-
|
|
147
|
-
_this.setState({
|
|
148
|
-
visible: false
|
|
149
|
-
});
|
|
150
|
-
};
|
|
151
|
-
|
|
152
|
-
_this.show = function (bindNode) {
|
|
153
|
-
// 提供给父组件调用,用于显示弹框
|
|
154
|
-
_this.setState({
|
|
155
|
-
visible: true,
|
|
156
|
-
bindNode: bindNode
|
|
157
|
-
});
|
|
158
|
-
};
|
|
159
|
-
|
|
160
|
-
_this.hide = function () {
|
|
161
|
-
// 提供给父组件调用,用于显示隐藏弹框
|
|
162
|
-
_this.setState({
|
|
163
|
-
visible: false
|
|
164
|
-
});
|
|
165
|
-
};
|
|
166
|
-
|
|
167
|
-
_this.clearBlurHandle = function () {
|
|
168
|
-
// 清除事件
|
|
169
|
-
window.document.removeEventListener("mousedown", _this.handleBlur);
|
|
170
|
-
_this.blurHandler = null;
|
|
171
|
-
};
|
|
172
|
-
|
|
173
|
-
_this.isVisible = function () {
|
|
174
|
-
return _this.state.visible;
|
|
175
|
-
};
|
|
176
|
-
|
|
177
|
-
_this.state = {
|
|
178
|
-
visible: false
|
|
179
|
-
};
|
|
180
|
-
_this.innerRef = /*#__PURE__*/_react["default"].createRef();
|
|
181
|
-
_this.popId = "t-pop-".concat((0, _uuid.v1)());
|
|
182
|
-
return _this;
|
|
183
|
-
}
|
|
184
|
-
|
|
185
|
-
_createClass(suspend, [{
|
|
186
|
-
key: "render",
|
|
187
|
-
value: function render() {
|
|
188
|
-
var _this$props2 = this.props,
|
|
189
|
-
onBeforeShow = _this$props2.onBeforeShow,
|
|
190
|
-
onAfterShow = _this$props2.onAfterShow;
|
|
191
|
-
|
|
192
|
-
var children = this.state.visible && /*#__PURE__*/_react["default"].createElement(_placement["default"], {
|
|
193
|
-
ref: "inner",
|
|
194
|
-
autoAdjust: this.props.autoAdjust,
|
|
195
|
-
container: this.props.container,
|
|
196
|
-
style: this.props.style,
|
|
197
|
-
className: this.props.className || "tita-common-pop",
|
|
198
|
-
align: this.props.align,
|
|
199
|
-
uid: this.popId,
|
|
200
|
-
cover: this.props.cover,
|
|
201
|
-
dragCls: this.props.dragCls,
|
|
202
|
-
getBindNode: this.getBindNode
|
|
203
|
-
}, this.props.children);
|
|
204
|
-
|
|
205
|
-
return [/*#__PURE__*/_react["default"].createElement(_animate["default"], {
|
|
206
|
-
key: "body-".concat(this.popId),
|
|
207
|
-
onEnter: {
|
|
208
|
-
start: onBeforeShow,
|
|
209
|
-
end: onAfterShow
|
|
210
|
-
},
|
|
211
|
-
transitionName: this.props.transitionName || "tita-common-pop",
|
|
212
|
-
onLeave: {
|
|
213
|
-
start: this.props.onBeforeHide
|
|
214
|
-
}
|
|
215
|
-
}, children) // <div style={{ display: 'block' }} key={`noop-${this.popId}`}></div>, // 这空div是干啥的???
|
|
216
|
-
];
|
|
217
|
-
}
|
|
218
|
-
}, {
|
|
219
|
-
key: "componentDidMount",
|
|
220
|
-
value: function componentDidMount() {
|
|
221
|
-
(0, _reactDom.findDOMNode)(this) && (0, _reactDom.findDOMNode)(this).parentNode.setAttribute("data-tita-pop", this.popId);
|
|
222
|
-
}
|
|
223
|
-
}, {
|
|
224
|
-
key: "componentDidUpdate",
|
|
225
|
-
value: function componentDidUpdate() {
|
|
226
|
-
if (this.props.blurToHide) {
|
|
227
|
-
this.state.visible ? this.bindBlurHandle() : this.clearBlurHandle();
|
|
228
|
-
}
|
|
229
|
-
}
|
|
230
|
-
}, {
|
|
231
|
-
key: "componentWillUnmount",
|
|
232
|
-
value: function componentWillUnmount() {
|
|
233
|
-
this.clearBlurHandle();
|
|
234
|
-
this.blurHandler = null;
|
|
235
|
-
}
|
|
236
|
-
}]);
|
|
237
|
-
|
|
238
|
-
return suspend;
|
|
239
|
-
}(_react.Component);
|
|
240
|
-
|
|
241
|
-
exports["default"] = suspend;
|
|
242
|
-
suspend.defaultProps = {
|
|
243
|
-
align: "bottom",
|
|
244
|
-
autoAdjust: "x y",
|
|
245
|
-
blurToHide: true
|
|
246
|
-
};
|
|
@@ -1,163 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
|
-
|
|
5
|
-
Object.defineProperty(exports, "__esModule", {
|
|
6
|
-
value: true
|
|
7
|
-
});
|
|
8
|
-
exports["default"] = void 0;
|
|
9
|
-
|
|
10
|
-
var _react = _interopRequireWildcard(require("react"));
|
|
11
|
-
|
|
12
|
-
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
13
|
-
|
|
14
|
-
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
15
|
-
|
|
16
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
17
|
-
|
|
18
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
19
|
-
|
|
20
|
-
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
21
|
-
|
|
22
|
-
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
23
|
-
|
|
24
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
25
|
-
|
|
26
|
-
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
27
|
-
|
|
28
|
-
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
29
|
-
|
|
30
|
-
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
31
|
-
|
|
32
|
-
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
33
|
-
|
|
34
|
-
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
|
35
|
-
|
|
36
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
37
|
-
|
|
38
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
39
|
-
|
|
40
|
-
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
41
|
-
|
|
42
|
-
var PopInner = /*#__PURE__*/function (_Component) {
|
|
43
|
-
_inherits(PopInner, _Component);
|
|
44
|
-
|
|
45
|
-
var _super = _createSuper(PopInner);
|
|
46
|
-
|
|
47
|
-
function PopInner(props) {
|
|
48
|
-
var _this;
|
|
49
|
-
|
|
50
|
-
_classCallCheck(this, PopInner);
|
|
51
|
-
|
|
52
|
-
_this = _super.call(this, props);
|
|
53
|
-
|
|
54
|
-
_this.caculPosition = function () {
|
|
55
|
-
if (!_this.props.bindNode) {
|
|
56
|
-
throw new error("需要传入bindNode");
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
var position = {}; // container距视窗左上角的位置
|
|
60
|
-
|
|
61
|
-
var containerOffset = _this.props.container.getBoundingClientRect(); // node距离视窗左上角的位置
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
var nodeOffset = _this.props.bindNode.getBoundingClientRect(); // bindNode距container左上角的位置
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
var nodeScrollOffset = {
|
|
68
|
-
top: _this.props.container.scrollTop + nodeOffset.top - containerOffset.top,
|
|
69
|
-
left: _this.props.container.scrollLeft + nodeOffset.left - containerOffset.left,
|
|
70
|
-
bottom: _this.props.container.scrollTop + nodeOffset.top - containerOffset.top + nodeOffset.height,
|
|
71
|
-
right: _this.props.container.scrollLeft + nodeOffset.left - containerOffset.left + nodeOffset.width
|
|
72
|
-
}; // pop的宽高
|
|
73
|
-
|
|
74
|
-
var popSize = _this.refs.wrapper.getBoundingClientRect();
|
|
75
|
-
|
|
76
|
-
var positionType = _this.props.position.split(/\s+/); // 确定pop的位置需要pop的宽高 bindNode相对视窗左上角的位置 bindNode相对container左上角的位置
|
|
77
|
-
// 其中bindNode相对container左上角的位置 = bindNode相对视窗左上角的位置 - container相对视窗左上角的位置 + container的滚动距离
|
|
78
|
-
// 是否需要自动调整pop的位置
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
var autoX = _this.props.autoAdjust == "x" || _this.props.autoAdjust == "x y";
|
|
82
|
-
var autoY = _this.props.autoAdjust == "y" || _this.props.autoAdjust == "x y"; // 确定显示在bindNode的上方还是下方
|
|
83
|
-
|
|
84
|
-
if (positionType[0] === "top") {
|
|
85
|
-
// 优先出现在bindNode顶部 顶部空间不够则出现在底部
|
|
86
|
-
if (!autoY || nodeOffset.top - (containerOffset.top < 0 ? 0 : containerOffset.top) >= popSize.height) {
|
|
87
|
-
position.top = "".concat(nodeScrollOffset.top - popSize.height, "px");
|
|
88
|
-
} else {
|
|
89
|
-
position.top = "".concat(nodeScrollOffset.bottom, "px");
|
|
90
|
-
}
|
|
91
|
-
} else {
|
|
92
|
-
// 优先出现在bindNode底部 底部空间不够则出现在顶部
|
|
93
|
-
if (!autoY || containerOffset.bottom >= nodeOffset.bottom + popSize.height) {
|
|
94
|
-
position.top = "".concat(nodeScrollOffset.bottom, "px");
|
|
95
|
-
} else {
|
|
96
|
-
position.top = "".concat(nodeScrollOffset.top - popSize.height, "px");
|
|
97
|
-
}
|
|
98
|
-
} // 确定横向的位置
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
if (positionType[1] == "right") {
|
|
102
|
-
// container中bindNode右侧的空间大于pop的宽度则将左边框对其bindNode的左边框
|
|
103
|
-
if (!autoX || containerOffset.right - nodeOffset.right >= popSize.width) {
|
|
104
|
-
position.left = "".concat(nodeScrollOffset.left, "px");
|
|
105
|
-
} else {
|
|
106
|
-
// 否则贴在右侧
|
|
107
|
-
position.left = "".concat(containerOffset.right - containerOffset.left - popSize.width, "px");
|
|
108
|
-
}
|
|
109
|
-
} else if (positionType[1] == "left") {
|
|
110
|
-
if (!autoX || nodeOffset.right - (containerOffset.left < 0 ? 0 : containerOffset.left) >= popSize.width) {
|
|
111
|
-
position.left = "".concat(nodeScrollOffset.right - popSize.width, "px");
|
|
112
|
-
} else {
|
|
113
|
-
position.left = "".concat(_this.props.container.scrollLeft, "px");
|
|
114
|
-
}
|
|
115
|
-
} else {
|
|
116
|
-
// 优先剧中
|
|
117
|
-
if (!autoX || containerOffset.right - nodeOffset.right >= (popSize.width - nodeOffset.width) / 2) {
|
|
118
|
-
position.left = "".concat(nodeScrollOffset.left - (popSize.width - nodeOffset.width) / 2, "px");
|
|
119
|
-
} else {
|
|
120
|
-
position.left = "".concat(containerOffset.right - containerOffset.left - popSize.width, "px");
|
|
121
|
-
}
|
|
122
|
-
|
|
123
|
-
if (autoX && nodeOffset.right - (containerOffset.left < 0 ? 0 : containerOffset.left) < (popSize.width + nodeOffset.width) / 2) {
|
|
124
|
-
position.left = "".concat(_this.props.container.scrollLeft, "px");
|
|
125
|
-
}
|
|
126
|
-
}
|
|
127
|
-
|
|
128
|
-
return position;
|
|
129
|
-
};
|
|
130
|
-
|
|
131
|
-
_this.state = {
|
|
132
|
-
visibility: "hidden",
|
|
133
|
-
position: {}
|
|
134
|
-
};
|
|
135
|
-
return _this;
|
|
136
|
-
}
|
|
137
|
-
|
|
138
|
-
_createClass(PopInner, [{
|
|
139
|
-
key: "componentDidMount",
|
|
140
|
-
value: function componentDidMount() {
|
|
141
|
-
this.setState({
|
|
142
|
-
visibility: "visible",
|
|
143
|
-
position: this.caculPosition()
|
|
144
|
-
});
|
|
145
|
-
}
|
|
146
|
-
}, {
|
|
147
|
-
key: "render",
|
|
148
|
-
value: function render() {
|
|
149
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
150
|
-
ref: "wrapper",
|
|
151
|
-
style: _objectSpread({
|
|
152
|
-
zIndex: 9999,
|
|
153
|
-
visibility: this.state.visibility,
|
|
154
|
-
position: "absolute"
|
|
155
|
-
}, this.state.position)
|
|
156
|
-
}, this.props.children);
|
|
157
|
-
}
|
|
158
|
-
}]);
|
|
159
|
-
|
|
160
|
-
return PopInner;
|
|
161
|
-
}(_react.Component);
|
|
162
|
-
|
|
163
|
-
exports["default"] = PopInner;
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports["default"] = void 0;
|
|
7
|
-
|
|
8
|
-
var _Pop = _interopRequireDefault(require("./Pop"));
|
|
9
|
-
|
|
10
|
-
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
11
|
-
|
|
12
|
-
var _default = _Pop["default"];
|
|
13
|
-
exports["default"] = _default;
|
|
@@ -1,152 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
|
-
|
|
5
|
-
Object.defineProperty(exports, "__esModule", {
|
|
6
|
-
value: true
|
|
7
|
-
});
|
|
8
|
-
exports["default"] = void 0;
|
|
9
|
-
|
|
10
|
-
var _react = _interopRequireWildcard(require("react"));
|
|
11
|
-
|
|
12
|
-
require("./index.scss");
|
|
13
|
-
|
|
14
|
-
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
15
|
-
|
|
16
|
-
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
17
|
-
|
|
18
|
-
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
19
|
-
|
|
20
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
21
|
-
|
|
22
|
-
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
23
|
-
|
|
24
|
-
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
25
|
-
|
|
26
|
-
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
27
|
-
|
|
28
|
-
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
29
|
-
|
|
30
|
-
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
|
31
|
-
|
|
32
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
33
|
-
|
|
34
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
35
|
-
|
|
36
|
-
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
37
|
-
|
|
38
|
-
var CircleProgress = /*#__PURE__*/function (_Component) {
|
|
39
|
-
_inherits(CircleProgress, _Component);
|
|
40
|
-
|
|
41
|
-
var _super = _createSuper(CircleProgress);
|
|
42
|
-
|
|
43
|
-
function CircleProgress() {
|
|
44
|
-
var _temp, _this;
|
|
45
|
-
|
|
46
|
-
_classCallCheck(this, CircleProgress);
|
|
47
|
-
|
|
48
|
-
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
49
|
-
args[_key] = arguments[_key];
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
return _possibleConstructorReturn(_this, (_temp = _this = _super.call.apply(_super, [this].concat(args)), _this.getTextContent = function () {
|
|
53
|
-
var _this$props = _this.props,
|
|
54
|
-
formatText = _this$props.formatText,
|
|
55
|
-
percent = _this$props.percent;
|
|
56
|
-
|
|
57
|
-
if (formatText) {
|
|
58
|
-
return formatText(percent);
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
return percent + getLocale("OKR_MyO_Pop_Upd_Percentage");
|
|
62
|
-
}, _temp));
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
_createClass(CircleProgress, [{
|
|
66
|
-
key: "render",
|
|
67
|
-
value: function render() {
|
|
68
|
-
var _this$props2 = this.props,
|
|
69
|
-
size = _this$props2.size,
|
|
70
|
-
color = _this$props2.color,
|
|
71
|
-
progress = _this$props2.progress,
|
|
72
|
-
width = _this$props2.width,
|
|
73
|
-
percent = _this$props2.percent,
|
|
74
|
-
backgroundColor = _this$props2.backgroundColor,
|
|
75
|
-
textcolor = _this$props2.textcolor,
|
|
76
|
-
linear = _this$props2.linear,
|
|
77
|
-
linearId = _this$props2.linearId,
|
|
78
|
-
linearStartColor = _this$props2.linearStartColor,
|
|
79
|
-
linearEndColor = _this$props2.linearEndColor,
|
|
80
|
-
showTextContent = _this$props2.showTextContent;
|
|
81
|
-
var p = percent > 100 ? 100 : percent;
|
|
82
|
-
var c = Math.round((size - width * 2) * Math.PI);
|
|
83
|
-
var remainC = Math.round(c * (100 - p) / 100);
|
|
84
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
85
|
-
className: "t-c-progress-circle",
|
|
86
|
-
style: {
|
|
87
|
-
width: "".concat(size, "px"),
|
|
88
|
-
height: "".concat(size, "px")
|
|
89
|
-
}
|
|
90
|
-
}, /*#__PURE__*/_react["default"].createElement("svg", {
|
|
91
|
-
width: size,
|
|
92
|
-
height: size,
|
|
93
|
-
viewBox: "0 0 ".concat(size, " ").concat(size)
|
|
94
|
-
}, /*#__PURE__*/_react["default"].createElement("circle", {
|
|
95
|
-
cx: size / 2,
|
|
96
|
-
cy: size / 2,
|
|
97
|
-
r: size / 2 - width,
|
|
98
|
-
fill: "none",
|
|
99
|
-
stroke: backgroundColor,
|
|
100
|
-
strokeWidth: width
|
|
101
|
-
}), /*#__PURE__*/_react["default"].createElement("circle", {
|
|
102
|
-
cx: size / 2,
|
|
103
|
-
cy: size / 2,
|
|
104
|
-
r: size / 2 - width,
|
|
105
|
-
fill: "none",
|
|
106
|
-
stroke: linear ? "url(#".concat(linearId, ")") : color,
|
|
107
|
-
strokeWidth: width,
|
|
108
|
-
strokeDasharray: c,
|
|
109
|
-
strokeDashoffset: remainC,
|
|
110
|
-
strokeLinecap: "round",
|
|
111
|
-
transform: "rotate(-90, ".concat(size / 2, " ").concat(size / 2, ")"),
|
|
112
|
-
style: {
|
|
113
|
-
transition: "stroke-dashoffset 0.3s ease 0s, stroke-dasharray 0.3s ease 0s, stroke 0.3s ease 0s, stroke-width 0.06s ease 0.3s"
|
|
114
|
-
}
|
|
115
|
-
}), /*#__PURE__*/_react["default"].createElement("defs", null, /*#__PURE__*/_react["default"].createElement("linearGradient", {
|
|
116
|
-
x1: "96.9769965%",
|
|
117
|
-
y1: "80.9878035%",
|
|
118
|
-
x2: "0%",
|
|
119
|
-
y2: "41.7547666%",
|
|
120
|
-
id: linearId
|
|
121
|
-
}, /*#__PURE__*/_react["default"].createElement("stop", {
|
|
122
|
-
stopColor: linearStartColor,
|
|
123
|
-
offset: "0%"
|
|
124
|
-
}), /*#__PURE__*/_react["default"].createElement("stop", {
|
|
125
|
-
stopColor: linearEndColor,
|
|
126
|
-
offset: "100%"
|
|
127
|
-
})))), showTextContent && /*#__PURE__*/_react["default"].createElement("div", {
|
|
128
|
-
className: "text-content",
|
|
129
|
-
style: {
|
|
130
|
-
color: textcolor
|
|
131
|
-
}
|
|
132
|
-
}, this.getTextContent()));
|
|
133
|
-
}
|
|
134
|
-
}]);
|
|
135
|
-
|
|
136
|
-
return CircleProgress;
|
|
137
|
-
}(_react.Component);
|
|
138
|
-
|
|
139
|
-
exports["default"] = CircleProgress;
|
|
140
|
-
CircleProgress.defaultProps = {
|
|
141
|
-
size: "100",
|
|
142
|
-
color: "#419BFF",
|
|
143
|
-
percent: 10,
|
|
144
|
-
width: "8",
|
|
145
|
-
backgroundColor: "#EBEDEE",
|
|
146
|
-
linear: false,
|
|
147
|
-
linearId: "linearGradient",
|
|
148
|
-
linearStartColor: "#4e90ff",
|
|
149
|
-
linearEndColor: "#2879ff",
|
|
150
|
-
showTextContent: true,
|
|
151
|
-
textcolor: "#565E66"
|
|
152
|
-
};
|
|
@@ -1,83 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
|
-
|
|
5
|
-
Object.defineProperty(exports, "__esModule", {
|
|
6
|
-
value: true
|
|
7
|
-
});
|
|
8
|
-
exports["default"] = void 0;
|
|
9
|
-
|
|
10
|
-
var _react = _interopRequireWildcard(require("react"));
|
|
11
|
-
|
|
12
|
-
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
13
|
-
|
|
14
|
-
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
15
|
-
|
|
16
|
-
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
17
|
-
|
|
18
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
19
|
-
|
|
20
|
-
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
21
|
-
|
|
22
|
-
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
23
|
-
|
|
24
|
-
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
25
|
-
|
|
26
|
-
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
27
|
-
|
|
28
|
-
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
|
29
|
-
|
|
30
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
31
|
-
|
|
32
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
33
|
-
|
|
34
|
-
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
35
|
-
|
|
36
|
-
var LineProgress = /*#__PURE__*/function (_Component) {
|
|
37
|
-
_inherits(LineProgress, _Component);
|
|
38
|
-
|
|
39
|
-
var _super = _createSuper(LineProgress);
|
|
40
|
-
|
|
41
|
-
function LineProgress() {
|
|
42
|
-
_classCallCheck(this, LineProgress);
|
|
43
|
-
|
|
44
|
-
return _super.apply(this, arguments);
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
_createClass(LineProgress, [{
|
|
48
|
-
key: "render",
|
|
49
|
-
value: function render() {
|
|
50
|
-
var _this$props = this.props,
|
|
51
|
-
color = _this$props.color,
|
|
52
|
-
backgroundColor = _this$props.backgroundColor,
|
|
53
|
-
size = _this$props.size,
|
|
54
|
-
percent = _this$props.percent;
|
|
55
|
-
var p = percent > 100 ? 100 : percent;
|
|
56
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
57
|
-
className: "t-c-progress-line",
|
|
58
|
-
style: {
|
|
59
|
-
backgroundColor: backgroundColor,
|
|
60
|
-
height: "".concat(size, "px"),
|
|
61
|
-
borderRadius: "".concat(size / 2, "px")
|
|
62
|
-
}
|
|
63
|
-
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
64
|
-
className: "line-inner",
|
|
65
|
-
style: {
|
|
66
|
-
background: color,
|
|
67
|
-
width: "".concat(p, "%"),
|
|
68
|
-
borderRadius: "0 ".concat(size / 2, "px ").concat(size / 2, "px 0")
|
|
69
|
-
}
|
|
70
|
-
}));
|
|
71
|
-
}
|
|
72
|
-
}]);
|
|
73
|
-
|
|
74
|
-
return LineProgress;
|
|
75
|
-
}(_react.Component);
|
|
76
|
-
|
|
77
|
-
exports["default"] = LineProgress;
|
|
78
|
-
LineProgress.defaultProps = {
|
|
79
|
-
color: " #419BFF",
|
|
80
|
-
backgroundColor: "#E3F4FF",
|
|
81
|
-
percent: 0,
|
|
82
|
-
size: 8
|
|
83
|
-
};
|