@titaui/pc 1.11.2 → 1.11.4-1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/es/components/cascader/time.js +31 -0
- package/es/components/common-share/request-apis.js +56 -0
- package/es/components/confidence/heart.js +66 -0
- package/es/components/create-okr-modal/fields/index.js +17 -0
- package/es/components/create-okr-modal/utils/getCreateOkrSurpassPercent.js +154 -0
- package/es/components/date-picker/BodyItem.js +121 -0
- package/es/components/date-picker/CalendarBody.js +157 -0
- package/es/components/date-picker/CalendarHeader.js +187 -0
- package/es/components/date-picker/index.js +157 -0
- package/es/components/date-range-picker/index.js +210 -0
- package/es/components/dialog/index.js +119 -0
- package/es/components/dialog-confirm/index.js +154 -0
- package/es/components/drop-selector/icon-item.js +40 -0
- package/es/components/drop-selector/index.js +179 -0
- package/es/components/dynamic/dynamic-like-ranking/mock.js +84 -0
- package/es/components/dynamic/dynamic-liking/mock.js +83 -0
- package/es/components/dynamic/dynamic-topping/request-api.js +36 -0
- package/es/components/e-priority/index.js +88 -0
- package/es/components/e-status-dropdown/index.js +94 -0
- package/es/components/grid-layout/commen-components/index.js +73 -0
- package/es/components/grid-layout/image/could.js +8 -0
- package/es/components/grid-layout/image/lv.js +8 -0
- package/es/components/grid-layout/image/tita-mask.js +8 -0
- package/es/components/help-card/request-api.js +35 -0
- package/es/components/icon-button-list/index.js +65 -0
- package/es/components/menus/context.js +18 -0
- package/es/components/menus/precls.js +8 -0
- package/es/components/okr-detail/auth.js +197 -0
- package/es/components/okr-detail/components/ao-nice/index.js +245 -0
- package/es/components/okr-detail/components/block-line/index.js +20 -0
- package/es/components/okr-detail/components/header/index.js +211 -0
- package/es/components/okr-detail/components/icon-text/index.js +116 -0
- package/es/components/okr-detail/components/okr-tree/index.js +48 -0
- package/es/components/okr-detail/components/okr-tree/precls.js +8 -0
- package/es/components/okr-detail/components/okr-tree/tree-node/default-node.js +22 -0
- package/es/components/okr-detail/components/okr-tree/tree-node/e-node/e-priority-dropdown.js +88 -0
- package/es/components/okr-detail/components/okr-tree/tree-node/e-node/e-project.js +200 -0
- package/es/components/okr-detail/components/okr-tree/tree-node/e-node/e-status-dropdown.js +98 -0
- package/es/components/okr-detail/components/okr-tree/tree-node/e-node/e-task-level2.js +412 -0
- package/es/components/okr-detail/components/okr-tree/tree-node/get-process-color.js +62 -0
- package/es/components/okr-detail/components/okr-tree/tree-node/index.js +90 -0
- package/es/components/okr-detail/components/okr-tree/tree-node/kr-node/get-process-color.js +46 -0
- package/es/components/okr-detail/components/okr-tree/tree-node/kr-node/index.js +421 -0
- package/es/components/okr-detail/components/okr-tree/tree-node/kr-node/kr-score-editor/index.js +54 -0
- package/es/components/okr-detail/components/okr-tree/tree-node/kr-node/kr-score-editor/style.js +62 -0
- package/es/components/okr-detail/components/okr-tree/tree-node/kr-node/range-picker-pop.js +94 -0
- package/es/components/okr-detail/components/okr-tree/tree-node/kr-parent-node/index.js +273 -0
- package/es/components/okr-detail/components/okr-tree/tree-node/o-child-node/index.js +207 -0
- package/es/components/okr-detail/components/okr-tree/tree-node/o-parent-node/index.js +236 -0
- package/es/components/okr-detail/components/padding-layout.js +22 -0
- package/es/components/okr-detail/components/tab-panel-content/index.js +27 -0
- package/es/components/okr-detail/context.js +30 -0
- package/es/components/okr-detail/e-list/index.js +243 -0
- package/es/components/okr-detail/e-list/precls.js +8 -0
- package/es/components/okr-detail/e-list/search-form/fields/e-order.js +172 -0
- package/es/components/okr-detail/e-list/search-form/fields/e-status.js +99 -0
- package/es/components/okr-detail/e-list/search-form/fields/e-user.js +49 -0
- package/es/components/okr-detail/e-list/search-form/index.js +143 -0
- package/es/components/okr-detail/error-page/index.js +33 -0
- package/es/components/okr-detail/index.js +428 -0
- package/es/components/okr-detail/loading/index.js +28 -0
- package/es/components/okr-detail/okr-list/add-parent-okr.js +37 -0
- package/es/components/okr-detail/okr-list/create-kr-item/heart.js +38 -0
- package/es/components/okr-detail/okr-list/drag-order-kr.js +62 -0
- package/es/components/okr-detail/okr-list/empty/index.js +48 -0
- package/es/components/okr-detail/okr-list/index.js +524 -0
- package/es/components/okr-detail/okr-list/warp-parent-okr.js +21 -0
- package/es/components/okr-detail/store.js +1 -0
- package/es/components/okr-flow/child-node/fields/creator.js +175 -0
- package/es/components/okr-flow/child-node/fields/okrClassify.js +31 -0
- package/es/components/okr-flow/child-node/fields/okrType.js +21 -0
- package/es/components/okr-flow/child-node/helper.js +35 -0
- package/es/components/okr-flow/child-node/index.js +110 -0
- package/es/components/okr-flow/child-node/kr-node.js +75 -0
- package/es/components/okr-flow/child-node/work-node.js +242 -0
- package/es/components/okr-flow/context.js +14 -0
- package/es/components/okr-flow/empty/index.js +29 -0
- package/es/components/okr-flow/export-modules/okr-search-panel/index.js +394 -0
- package/es/components/okr-flow/index.js +24 -0
- package/es/components/okr-flow/mini-map/index.js +112 -0
- package/es/components/okr-flow/mini-map/map.js +145 -0
- package/es/components/okr-flow/mini-map/mini-node.js +57 -0
- package/es/components/okr-flow/mini-map/utils.js +79 -0
- package/es/components/okr-flow/okr-map/index.js +192 -0
- package/es/components/okr-flow/open-data/index.js +115 -0
- package/es/components/okr-flow/precls.js +8 -0
- package/es/components/okr-flow/request-apis.js +118 -0
- package/es/components/okr-flow/root-node/index.js +229 -0
- package/es/components/okr-flow/utils/config.js +18 -0
- package/es/components/okr-flow/utils/helper.js +36 -0
- package/es/components/okr-flow/utils/index.js +66 -0
- package/es/components/okr-flow/utils/tree-handler.js +323 -0
- package/es/components/okr-progress-modal/helper.js +156 -0
- package/es/components/okr-progress-modal/request-apis.js +34 -0
- package/es/components/okr-share/request-apis.js +56 -0
- package/es/components/okrcase-library/server/network.js +407 -0
- package/es/components/pagination/locale/en_US.js +22 -0
- package/es/components/pagination/locale/zh_CN.js +22 -0
- package/es/components/point-demo/drop-down-box/index.js +159 -0
- package/es/components/point-demo/index.js +533 -0
- package/es/components/point-demo/input/index.js +176 -0
- package/es/components/point-demo/point-demo.js +75 -0
- package/es/components/point-demo/popup/index.js +113 -0
- package/es/components/point-demo/popup/placement.js +44 -0
- package/es/components/range-picker-pop/index.js +273 -0
- package/es/components/scrollbar/simplebar/helpers.js +59 -0
- package/es/components/scrollbar/simplebar/index.js +91 -0
- package/es/components/scrollbar/simplebar/scrollbar-width.js +47 -0
- package/es/components/scrollbar/simplebar/simplebar.js +852 -0
- package/es/components/scrollbar/simplebar-react.js +163 -0
- package/es/components/search-dropdown/index.js +40 -0
- package/es/components/search-input/index.js +126 -0
- package/es/components/select/Option.js +94 -0
- package/es/components/select/index.js +330 -0
- package/es/components/selector-input/debounce.js +36 -0
- package/es/components/selector-input/index.js +109 -0
- package/es/components/slider-input/index.js +119 -0
- package/es/components/switch/index.js +39 -0
- package/es/components/table/index.js +275 -0
- package/es/components/tabs/index.js +63 -0
- package/es/components/task-relation-modal/tree-node/index.js +58 -0
- package/es/components/tita-chart/charts/img/could.js +8 -0
- package/es/components/tooltip/error-tip.js +24 -0
- package/es/components/tooltip/index.js +21 -0
- package/es/components/tree/index.js +79 -0
- package/es/components/tree/precls.js +8 -0
- package/es/components/upvote/request-apis.js +45 -0
- package/es/components/user-selector/action-btns/btn-cancel.js +21 -0
- package/es/components/user-selector/action-btns/btn-ok.js +21 -0
- package/es/components/user-selector/action-btns/index.js +27 -0
- package/es/components/user-selector/context.js +18 -0
- package/es/components/user-selector/empty/group.js +55 -0
- package/es/components/user-selector/empty/index.js +28 -0
- package/es/components/user-selector/export-modules/depart-search-selector/result-part.js +41 -0
- package/es/components/user-selector/export-modules/group-selector/index.js +170 -0
- package/es/components/user-selector/export-modules/group-selector/searched-panel.js +68 -0
- package/es/components/user-selector/export-modules/multiple-user-selector--bak/index.js +246 -0
- package/es/components/user-selector/index.js +25 -0
- package/es/components/user-selector/layout/index.js +25 -0
- package/es/components/user-selector/loading/index.js +18 -0
- package/es/components/user-selector/request-apis.js +180 -0
- package/es/components/user-selector/searched-panel/index.js +139 -0
- package/es/components/user-selector/searched-panel/result-part.js +43 -0
- package/es/components/user-selector/select-tree/selected-tree/index.js +91 -0
- package/es/components/user-selector/select-tree/tree-nodes/tree-depart-node/index.js +48 -0
- package/es/components/user-selector/select-tree/tree-nodes/tree-duties-node/index.js +27 -0
- package/es/components/user-selector/select-tree/tree-nodes/tree-group-node/index.js +57 -0
- package/es/components/user-selector/select-tree/tree-nodes/tree-person-node/index.js +93 -0
- package/es/components/user-selector/utils.js +139 -0
- package/es/components/viewer/ImageListRender.js +143 -0
- package/es/components/viewer/index.js +168 -0
- package/es/components/word-cloud/index.js +109 -0
- package/es/components/word-cloud/request-apis.js +26 -0
- package/es/components-v1/animate/AnimateChild.js +76 -0
- package/es/components-v1/animate/animate.js +148 -0
- package/es/components-v1/animate/index.js +13 -0
- package/es/components-v1/dom/index.js +30 -0
- package/es/components-v1/placement/index.js +13 -0
- package/es/components-v1/placement/placement.js +111 -0
- package/es/components-v1/placement/placementInner.js +139 -0
- package/es/components-v1/pop/Pop.js +246 -0
- package/es/components-v1/pop/PopInner.js +163 -0
- package/es/components-v1/pop/index.js +13 -0
- package/es/components-v1/progress/CircleProgress.js +152 -0
- package/es/components-v1/progress/LineProgress.js +83 -0
- package/es/components-v1/progress/index.js +80 -0
- package/es/components-v1/select/Option.js +94 -0
- package/es/components-v1/select/index.js +330 -0
- package/es/components-v1/utils/animate/animate.js +103 -0
- package/es/components-v1/utils/animate/event.js +79 -0
- package/es/components-v1/utils/dom/index.js +30 -0
- package/es/components-v1/utils/placement/autoAdjustPlacement.js +93 -0
- package/es/components-v1/utils/placement/getContainerVisibleArea.js +22 -0
- package/es/components-v1/utils/placement/getExpectPlacement.js +49 -0
- package/es/components-v1/utils/placement/getPlacementInContainer.js +26 -0
- package/es/components-v1/utils/placement/placement.js +76 -0
- package/es/index.js +777 -0
- package/es/pages/appointment-demo/drop-down-box/index.js +159 -0
- package/es/pages/appointment-demo/index.js +649 -0
- package/es/pages/appointment-demo/input/index.js +176 -0
- package/es/pages/appointment-demo/popup/index.js +113 -0
- package/es/pages/appointment-demo/popup/placement.js +44 -0
- package/es/pages/group-management/components/checkbox/index.js +28 -0
- package/es/pages/group-management/components/input-form/index.js +174 -0
- package/es/pages/group-management/components/radio/index.js +21 -0
- package/es/pages/group-management/components/table/index.js +174 -0
- package/es/pages/group-management/groupInterface.js +293 -0
- package/es/pages/group-management/index.js +13 -0
- package/es/pages/group-management/page-view/empty.js +111 -0
- package/es/pages/group-management/page-view/group-empty.js +66 -0
- package/es/pages/group-management/page-view/importGroupStaff/index.js +208 -0
- package/es/pages/group-management/page-view/index.js +412 -0
- package/es/pages/group-management/page-view/loading/index.js +32 -0
- package/es/pages/group-management/table/index.js +104 -0
- package/es/pages/group-management/tree/add-group-dialog/index.js +153 -0
- package/es/pages/group-management/tree/delete-group-dialog/index.js +82 -0
- package/es/pages/group-management/tree/edit-group-dialog/index.js +155 -0
- package/es/pages/group-management/tree/group-form/index.js +207 -0
- package/es/pages/group-management/tree/index.js +168 -0
- package/es/pages/group-management/tree/operation-panel.js +41 -0
- package/es/pages/group-management/tree/trigger-render.js +99 -0
- package/es/pages/like-ranking/mock.js +366 -0
- package/es/pages/okr-map/export-modules/index.js +1 -0
- package/es/pages/okr-map/export-modules/okr-map/header/index.js +182 -0
- package/es/pages/okr-map/export-modules/okr-map/header/show-kr-confirm.js +47 -0
- package/es/pages/okr-map/export-modules/okr-map/okr-map.js +497 -0
- package/es/pages/okr-map/export-modules/share-okr-page/header/index.js +69 -0
- package/es/pages/okr-map/export-modules/share-okr-page/share-okr-map.js +168 -0
- package/es/pages/okr-map/hooks/useStorage.js +96 -0
- package/es/pages/okr-map/index.js +18 -0
- package/es/pages/okr-map/level2-search/depart.js +53 -0
- package/es/pages/okr-map/level2-search/group.js +69 -0
- package/es/pages/okr-map/level2-search/index.js +51 -0
- package/es/pages/okr-map/level2-search/level2-input.js +46 -0
- package/es/pages/okr-map/level2-search/user.js +54 -0
- package/es/pages/okr-map/no-okr/index.js +24 -0
- package/es/pages/okr-map/number-select/index.js +81 -0
- package/es/pages/okr-map/open-data/index.js +115 -0
- package/es/pages/okr-map/precls.js +8 -0
- package/es/pages/okr-map/request-apis.js +76 -0
- package/es/pages/okr-map/share-dialog/index.js +122 -0
- package/es/pages/okr-map/unsupport-ie/index.js +83 -0
- package/es/pages/okr-map/utils.js +51 -0
- package/es/utils/auth.js +294 -0
- package/es/utils/bs-global.js +114 -0
- package/es/utils/local-storage.js +42 -0
- package/es/utils/mblog.js +33 -0
- package/es/utils/mock-bsglobal.js +1837 -0
- package/es/utils/open-data.js +341 -0
- package/es/utils/request-v1.js +115 -0
- package/es/utils/request.js +183 -0
- package/es/utils/tools.js +286 -0
- package/lib/components/button/icon-btn/index.js +17 -8
- 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/drop-selector/index.js +25 -10
- package/lib/components/dynamic/constant.js +31 -31
- package/lib/components/dynamic/dynamic-item/dynamic-interview/img/wifi.svg +24 -0
- package/lib/components/dynamic/dynamic-item/dynamic-interview/index.css +36 -0
- package/lib/components/dynamic/dynamic-item/dynamic-interview/index.js +51 -0
- package/lib/components/dynamic/dynamic-item/dynamic-interview/interview-content.js +53 -0
- package/lib/components/dynamic/dynamic-item/index.js +40 -32
- package/lib/components/eReport/eReportLists/reportList.js +3 -3
- package/lib/components/emotions-selector/selector-pop.js +3 -3
- package/lib/components/ereport-list/index.js +3 -3
- package/lib/components/form/form-fields/date/index.css +24 -0
- package/lib/components/form/form-fields/date/index.js +98 -0
- package/lib/components/form/form-fields/user/index.css +1 -1
- package/lib/components/form/index.js +10 -3
- package/lib/components/mblog/components/MblogAction.js +3 -3
- package/lib/components/menus/export-modules/interview-menus/constant.js +30 -0
- package/lib/components/menus/export-modules/interview-menus/handle-highlight.js +63 -0
- package/lib/components/menus/export-modules/interview-menus/index.js +126 -0
- package/lib/components/menus/index.js +11 -5
- package/lib/components/okr-detail/components/okr-tree/tree-node/kr-node/kr-score-editor/edit-pop.js +3 -3
- package/lib/components/okr-progress-modal/index.css +1 -1
- 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/picker/components/panels/date-panel/date-body.js +116 -0
- package/lib/components/picker/components/panels/date-panel/date-head.js +66 -0
- package/lib/components/picker/components/panels/date-panel/index.css +14 -0
- package/lib/components/picker/components/panels/date-panel/index.js +49 -0
- package/lib/components/picker/components/panels/month-panel/index.css +27 -0
- package/lib/components/picker/components/panels/month-panel/index.js +63 -0
- package/lib/components/picker/components/panels/month-panel/month-body.js +87 -0
- package/lib/components/picker/components/panels/month-panel/month-head.js +47 -0
- package/lib/components/picker/components/panels/panel-body/index.js +53 -0
- package/lib/components/picker/components/panels/panel-head/index.js +48 -0
- package/lib/components/picker/components/panels/year-panel/index.css +23 -0
- package/lib/components/picker/components/panels/year-panel/index.js +65 -0
- package/lib/components/picker/components/panels/year-panel/year-body.js +92 -0
- package/lib/components/picker/components/panels/year-panel/year-head.js +35 -0
- package/lib/components/picker/components/picker-trigger/index.css +42 -0
- package/lib/components/picker/components/picker-trigger/index.js +94 -0
- package/lib/components/picker/context.js +15 -0
- package/lib/components/picker/index.css +121 -0
- package/lib/components/picker/index.js +13 -0
- package/lib/components/picker/picker-panels.js +182 -0
- package/lib/components/picker/picker.js +132 -0
- package/lib/components/picker/type.js +5 -0
- package/lib/components/picker/utils.js +28 -0
- 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/select/Option.js +3 -3
- package/lib/components/time-picker/index.css +117 -0
- package/lib/components/time-picker/index.js +13 -0
- package/lib/components/time-picker/time-picker-selector.js +138 -0
- package/lib/components/time-picker/time-picker.js +324 -0
- package/lib/components/time-picker/timer-picker-input.js +94 -0
- package/lib/components/time-picker/utils.js +52 -0
- package/lib/components/tita-chart/errorBoundary/index.js +3 -3
- 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/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 +16 -0
- package/lib/pages/aha2021/index.js +5 -1
- package/lib/utils/hooks.js +72 -0
- package/package.json +1 -1
- package/yarn-error.log +21252 -0
|
@@ -0,0 +1,286 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.changeQueryString = changeQueryString;
|
|
7
|
+
exports.getQueryString = getQueryString;
|
|
8
|
+
exports.highLightWord = exports.hexToRgba = exports.getUrlForUserPage = void 0;
|
|
9
|
+
exports.htmlDecodeByHtmlRegExp = htmlDecodeByHtmlRegExp;
|
|
10
|
+
exports.htmlDecodeByRegExp = htmlDecodeByRegExp;
|
|
11
|
+
exports.htmlEncodeByRegExp = htmlEncodeByRegExp;
|
|
12
|
+
exports.htmlEncodeToHtmlByRegExp = htmlEncodeToHtmlByRegExp;
|
|
13
|
+
exports.unHighLight = exports.openPage = exports.htmlToText = void 0;
|
|
14
|
+
|
|
15
|
+
var _platform = require("./platform");
|
|
16
|
+
|
|
17
|
+
var _openData = require("./open-data");
|
|
18
|
+
|
|
19
|
+
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; }
|
|
20
|
+
|
|
21
|
+
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; }
|
|
22
|
+
|
|
23
|
+
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; }
|
|
24
|
+
|
|
25
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
26
|
+
|
|
27
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
28
|
+
|
|
29
|
+
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); }
|
|
30
|
+
|
|
31
|
+
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; }
|
|
32
|
+
|
|
33
|
+
function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"]; if (_i == null) return; var _arr = []; var _n = true; var _d = false; var _s, _e; try { for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
|
|
34
|
+
|
|
35
|
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
36
|
+
|
|
37
|
+
function htmlEncodeByRegExp(str) {
|
|
38
|
+
if (!str) return "";
|
|
39
|
+
var htmlString = {
|
|
40
|
+
"<": "<",
|
|
41
|
+
">": ">",
|
|
42
|
+
// "&": '&',
|
|
43
|
+
"'": "'",
|
|
44
|
+
"\"": """
|
|
45
|
+
};
|
|
46
|
+
return str.replace(/[<>'"]/g, function (s) {
|
|
47
|
+
return htmlString[s];
|
|
48
|
+
});
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
function htmlDecodeByRegExp(str) {
|
|
52
|
+
if (!str) return "";
|
|
53
|
+
var arrEntities = {
|
|
54
|
+
lt: "<",
|
|
55
|
+
gt: ">",
|
|
56
|
+
nbsp: " ",
|
|
57
|
+
amp: "&",
|
|
58
|
+
quot: "\"",
|
|
59
|
+
"#39": "'"
|
|
60
|
+
};
|
|
61
|
+
return str.replace(/&(lt|gt|nbsp|amp|quot|#39);/gi, function (all, t) {
|
|
62
|
+
return arrEntities[t];
|
|
63
|
+
});
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
function changeQueryString(key, value) {
|
|
67
|
+
var hash = decodeURIComponent(window.location.hash);
|
|
68
|
+
var queryObject = {};
|
|
69
|
+
var markIndex = hash.indexOf("?"); // contain query string in fragments
|
|
70
|
+
|
|
71
|
+
if (markIndex > -1) {
|
|
72
|
+
// build query object
|
|
73
|
+
var hashName = hash.slice(0, markIndex);
|
|
74
|
+
var queryString = hash.slice(markIndex + 1);
|
|
75
|
+
var queryArray = queryString.split("&");
|
|
76
|
+
queryArray.forEach(function (item) {
|
|
77
|
+
var _item$split = item.split("="),
|
|
78
|
+
_item$split2 = _slicedToArray(_item$split, 2),
|
|
79
|
+
tempItem0 = _item$split2[0],
|
|
80
|
+
tempItem1 = _item$split2[1];
|
|
81
|
+
|
|
82
|
+
queryObject[tempItem0] = tempItem1;
|
|
83
|
+
});
|
|
84
|
+
queryObject[key] = value;
|
|
85
|
+
var arr = [];
|
|
86
|
+
Object.keys(queryObject).forEach(function (name) {
|
|
87
|
+
arr.push("".concat(name, "=").concat(queryObject[name]));
|
|
88
|
+
});
|
|
89
|
+
window.location.hash = "".concat(hashName, "?").concat(arr.join("&"));
|
|
90
|
+
} else {
|
|
91
|
+
window.location.hash = hash;
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
function getQueryString() {
|
|
96
|
+
// 获取Url上的参数,以{}返回
|
|
97
|
+
var hash = decodeURIComponent(window.location.hash);
|
|
98
|
+
var queryObject = {};
|
|
99
|
+
var markIndex = hash.indexOf("?"); // contain query string in fragments
|
|
100
|
+
|
|
101
|
+
if (markIndex > -1) {
|
|
102
|
+
// build query object
|
|
103
|
+
var queryString = hash.slice(markIndex + 1);
|
|
104
|
+
var queryArray = queryString.split("&");
|
|
105
|
+
|
|
106
|
+
for (var i = 0; i < queryArray.length; i += 1) {
|
|
107
|
+
var queryPair = queryArray[i].split("=");
|
|
108
|
+
|
|
109
|
+
if (queryPair[0] !== "_k") {
|
|
110
|
+
queryObject[queryPair[0]] = decodeURIComponent(queryPair[1]);
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
return queryObject;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
var highLightWord = function highLightWord(_ref) {
|
|
119
|
+
var parentDom = _ref.parentDom,
|
|
120
|
+
_ref$keyWord = _ref.keyWord,
|
|
121
|
+
keyWord = _ref$keyWord === void 0 ? "" : _ref$keyWord,
|
|
122
|
+
_ref$className = _ref.className,
|
|
123
|
+
className = _ref$className === void 0 ? "highlight" : _ref$className,
|
|
124
|
+
_ref$nodeType = _ref.nodeType,
|
|
125
|
+
nodeType = _ref$nodeType === void 0 ? "span" : _ref$nodeType;
|
|
126
|
+
|
|
127
|
+
if (parentDom && keyWord) {
|
|
128
|
+
var reg = new RegExp(keyWord, "i");
|
|
129
|
+
|
|
130
|
+
if (parentDom.nodeType === 3) {
|
|
131
|
+
var match = parentDom.data.match(reg);
|
|
132
|
+
var currentDom = parentDom;
|
|
133
|
+
|
|
134
|
+
while (match) {
|
|
135
|
+
var highlight = document.createElement(nodeType);
|
|
136
|
+
highlight.className = className;
|
|
137
|
+
var wordNode = currentDom.splitText(match.index);
|
|
138
|
+
currentDom = wordNode.splitText(match[0].length);
|
|
139
|
+
var wordClone = wordNode.cloneNode(true);
|
|
140
|
+
highlight.appendChild(wordClone);
|
|
141
|
+
wordNode.parentNode.replaceChild(highlight, wordNode);
|
|
142
|
+
match = currentDom.data.match(reg);
|
|
143
|
+
}
|
|
144
|
+
} else {
|
|
145
|
+
var doms = Array.from(parentDom.childNodes);
|
|
146
|
+
|
|
147
|
+
if (doms && doms.length > 0) {
|
|
148
|
+
doms.forEach(function (dom) {
|
|
149
|
+
// @ts-ignore 1是元素 3是文本节点
|
|
150
|
+
if (dom.nodeType === 3) {
|
|
151
|
+
var _match = dom.data.match(reg);
|
|
152
|
+
|
|
153
|
+
var _currentDom = dom;
|
|
154
|
+
|
|
155
|
+
while (_match) {
|
|
156
|
+
var _highlight = document.createElement(nodeType);
|
|
157
|
+
|
|
158
|
+
_highlight.className = className;
|
|
159
|
+
|
|
160
|
+
var _wordNode = _currentDom.splitText(_match.index);
|
|
161
|
+
|
|
162
|
+
_currentDom = _wordNode.splitText(_match[0].length);
|
|
163
|
+
|
|
164
|
+
var _wordClone = _wordNode.cloneNode(true);
|
|
165
|
+
|
|
166
|
+
_highlight.appendChild(_wordClone);
|
|
167
|
+
|
|
168
|
+
_wordNode.parentNode.replaceChild(_highlight, _wordNode);
|
|
169
|
+
|
|
170
|
+
_match = _currentDom.data.match(reg);
|
|
171
|
+
}
|
|
172
|
+
} else if (dom.nodeType === 1 && dom.childNodes) {
|
|
173
|
+
for (var i = 0; i < dom.childNodes.length; i += 1) {
|
|
174
|
+
i += highLightWord({
|
|
175
|
+
parentDom: dom.childNodes[i],
|
|
176
|
+
keyWord: keyWord
|
|
177
|
+
});
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
});
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
};
|
|
185
|
+
|
|
186
|
+
exports.highLightWord = highLightWord;
|
|
187
|
+
|
|
188
|
+
var unHighLight = function unHighLight(_ref2) {
|
|
189
|
+
var parentDom = _ref2.parentDom,
|
|
190
|
+
_ref2$className = _ref2.className,
|
|
191
|
+
className = _ref2$className === void 0 ? "highlight" : _ref2$className,
|
|
192
|
+
_ref2$nodeType = _ref2.nodeType,
|
|
193
|
+
nodeType = _ref2$nodeType === void 0 ? "span" : _ref2$nodeType;
|
|
194
|
+
var doms = parentDom.querySelectorAll("".concat(nodeType, " .").concat(className));
|
|
195
|
+
|
|
196
|
+
if (doms) {
|
|
197
|
+
doms.forEach(function (dom) {
|
|
198
|
+
var parentNode = dom.parentNode;
|
|
199
|
+
var firstChild = dom.firstChild;
|
|
200
|
+
parentNode.replaceChild(firstChild, dom);
|
|
201
|
+
parentNode.normalize();
|
|
202
|
+
});
|
|
203
|
+
}
|
|
204
|
+
};
|
|
205
|
+
|
|
206
|
+
exports.unHighLight = unHighLight;
|
|
207
|
+
|
|
208
|
+
var hexToRgba = function hexToRgba(hex) {
|
|
209
|
+
var opacity = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 1;
|
|
210
|
+
return "rgba(".concat(parseInt("0x".concat(hex.slice(1, 3)), 16), ",").concat(parseInt("0x".concat(hex.slice(3, 5)), 16), ",").concat(parseInt("0x".concat(hex.slice(5, 7)), 16), ",").concat(opacity, ")");
|
|
211
|
+
};
|
|
212
|
+
|
|
213
|
+
exports.hexToRgba = hexToRgba;
|
|
214
|
+
|
|
215
|
+
var getUrlForUserPage = function getUrlForUserPage(options) {
|
|
216
|
+
var defults = {
|
|
217
|
+
userId: "",
|
|
218
|
+
// 是否是外部联系人,外部联系人没有 2是外部联系人
|
|
219
|
+
userType: 2
|
|
220
|
+
};
|
|
221
|
+
|
|
222
|
+
var configs = _objectSpread(_objectSpread({}, defults), options);
|
|
223
|
+
|
|
224
|
+
if (!configs.userId || (0, _platform.isDD)(true) || (0, _platform.isFeishu)(true) || configs.userType === 2) {
|
|
225
|
+
return "";
|
|
226
|
+
}
|
|
227
|
+
|
|
228
|
+
var userInfo = window.BSGlobal.loginUserInfo;
|
|
229
|
+
|
|
230
|
+
if (configs.userId === undefined) {
|
|
231
|
+
configs.userId = userInfo.Id;
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
var urlHost = window.BSGlobal.titaHost;
|
|
235
|
+
var homeUrl = "".concat(urlHost, "/").concat(userInfo.Id, "/PageBuilderForEdit#/view?to_user_id=").concat(configs.userId);
|
|
236
|
+
var homeCenter = "".concat(urlHost, "/u/").concat(userInfo.Id, "/Home#").concat(encodeURIComponent("widget/italent?iTalentFrameType=iframe&iTalentFrame=".concat(encodeURIComponent(homeUrl))));
|
|
237
|
+
return homeCenter;
|
|
238
|
+
};
|
|
239
|
+
|
|
240
|
+
exports.getUrlForUserPage = getUrlForUserPage;
|
|
241
|
+
|
|
242
|
+
var openPage = function openPage(url) {
|
|
243
|
+
if ((0, _openData.isPlatform)("dd")) {
|
|
244
|
+
window.open(url, "_self");
|
|
245
|
+
} else {
|
|
246
|
+
window.open(url, "_blank");
|
|
247
|
+
}
|
|
248
|
+
}; // html标签转义
|
|
249
|
+
|
|
250
|
+
|
|
251
|
+
exports.openPage = openPage;
|
|
252
|
+
|
|
253
|
+
function htmlEncodeToHtmlByRegExp(str) {
|
|
254
|
+
var temp = "";
|
|
255
|
+
if (str.length === 0) return ""; // temp = str.replace(/&/g, "&")
|
|
256
|
+
|
|
257
|
+
temp = str.replace(/</g, "<");
|
|
258
|
+
temp = temp.replace(/>/g, ">"); // temp = temp.replace(/ /g, " ")
|
|
259
|
+
|
|
260
|
+
temp = temp.replace(/'/g, "'");
|
|
261
|
+
temp = temp.replace(/"/g, """);
|
|
262
|
+
temp = temp.replace(/\n/g, "<br/>");
|
|
263
|
+
return temp;
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
function htmlDecodeByHtmlRegExp(str) {
|
|
267
|
+
var temp = "";
|
|
268
|
+
if (str.length === 0) return "";
|
|
269
|
+
temp = str.replace(/&/g, "&");
|
|
270
|
+
temp = temp.replace(/</g, "<");
|
|
271
|
+
temp = temp.replace(/>/g, ">");
|
|
272
|
+
temp = temp.replace(/ /g, " ");
|
|
273
|
+
temp = temp.replace(/'/g, "'");
|
|
274
|
+
temp = temp.replace(/"/g, "\"");
|
|
275
|
+
temp = temp.replace(/<br\/>/g, "\n");
|
|
276
|
+
return temp;
|
|
277
|
+
}
|
|
278
|
+
|
|
279
|
+
var htmlToText = function htmlToText(text) {
|
|
280
|
+
var div = document.createElement("div");
|
|
281
|
+
div.innerHTML = text;
|
|
282
|
+
var newtext = div.innerText || div.textContent;
|
|
283
|
+
return newtext;
|
|
284
|
+
};
|
|
285
|
+
|
|
286
|
+
exports.htmlToText = htmlToText;
|
|
@@ -11,11 +11,19 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
11
11
|
|
|
12
12
|
require("./index.css");
|
|
13
13
|
|
|
14
|
+
var _excluded = ["border", "theme", "onClick", "disabled", "icon"];
|
|
15
|
+
|
|
14
16
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
15
17
|
|
|
18
|
+
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
19
|
+
|
|
16
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; }
|
|
17
21
|
|
|
18
|
-
var
|
|
22
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
23
|
+
|
|
24
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
25
|
+
|
|
26
|
+
var precls = 'titaui-icon-btn';
|
|
19
27
|
|
|
20
28
|
function IconBtn(props) {
|
|
21
29
|
var _classNames;
|
|
@@ -24,15 +32,16 @@ function IconBtn(props) {
|
|
|
24
32
|
theme = props.theme,
|
|
25
33
|
onClick = props.onClick,
|
|
26
34
|
disabled = props.disabled,
|
|
27
|
-
icon = props.icon
|
|
35
|
+
icon = props.icon,
|
|
36
|
+
restProps = _objectWithoutProperties(props, _excluded);
|
|
28
37
|
|
|
29
38
|
var onClickHandler = function onClickHandler() {
|
|
30
39
|
if (disabled) return;
|
|
31
|
-
onClick
|
|
40
|
+
onClick === null || onClick === void 0 ? void 0 : onClick();
|
|
32
41
|
};
|
|
33
42
|
|
|
34
43
|
var renderIcon = function renderIcon() {
|
|
35
|
-
if (typeof icon ===
|
|
44
|
+
if (typeof icon === 'string') {
|
|
36
45
|
return /*#__PURE__*/_react["default"].createElement("span", {
|
|
37
46
|
className: "".concat(precls, "__icon")
|
|
38
47
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
@@ -45,18 +54,18 @@ function IconBtn(props) {
|
|
|
45
54
|
}, icon);
|
|
46
55
|
};
|
|
47
56
|
|
|
48
|
-
return /*#__PURE__*/_react["default"].createElement("span", {
|
|
57
|
+
return /*#__PURE__*/_react["default"].createElement("span", _extends({
|
|
49
58
|
className: (0, _classnames["default"])(precls, "".concat(precls, "--").concat(theme), (_classNames = {}, _defineProperty(_classNames, "".concat(precls, "--border"), border), _defineProperty(_classNames, "".concat(precls, "--disabled"), disabled), _classNames)),
|
|
50
59
|
onClick: onClickHandler
|
|
51
|
-
}, renderIcon());
|
|
60
|
+
}, restProps), renderIcon());
|
|
52
61
|
}
|
|
53
62
|
|
|
54
63
|
IconBtn.defaultProps = {
|
|
55
64
|
border: false,
|
|
56
|
-
theme:
|
|
65
|
+
theme: 'gray',
|
|
57
66
|
onClick: function onClick() {},
|
|
58
67
|
disabled: false,
|
|
59
|
-
icon:
|
|
68
|
+
icon: 'tu-icon-smile'
|
|
60
69
|
};
|
|
61
70
|
var _default = IconBtn;
|
|
62
71
|
exports["default"] = _default;
|
|
@@ -47,7 +47,7 @@ var BodyItem = /*#__PURE__*/function (_Component) {
|
|
|
47
47
|
var _super = _createSuper(BodyItem);
|
|
48
48
|
|
|
49
49
|
function BodyItem() {
|
|
50
|
-
var _this;
|
|
50
|
+
var _temp, _this;
|
|
51
51
|
|
|
52
52
|
_classCallCheck(this, BodyItem);
|
|
53
53
|
|
|
@@ -55,7 +55,7 @@ var BodyItem = /*#__PURE__*/function (_Component) {
|
|
|
55
55
|
args[_key] = arguments[_key];
|
|
56
56
|
}
|
|
57
57
|
|
|
58
|
-
return _possibleConstructorReturn(_this, (_this = _super.call.apply(_super, [this].concat(args)), _this.getClass = function () {
|
|
58
|
+
return _possibleConstructorReturn(_this, (_temp = _this = _super.call.apply(_super, [this].concat(args)), _this.getClass = function () {
|
|
59
59
|
var _this$props = _this.props,
|
|
60
60
|
isAllowSelect = _this$props.isAllowSelect,
|
|
61
61
|
date = _this$props.date,
|
|
@@ -86,7 +86,7 @@ var BodyItem = /*#__PURE__*/function (_Component) {
|
|
|
86
86
|
if (_this.disabled) return;
|
|
87
87
|
|
|
88
88
|
_this.props.onSelectDate((0, _moment["default"])(date.format("YYYY/MM/DD")));
|
|
89
|
-
},
|
|
89
|
+
}, _temp));
|
|
90
90
|
}
|
|
91
91
|
|
|
92
92
|
_createClass(BodyItem, [{
|
|
@@ -87,7 +87,7 @@ var CalendarHeader = /*#__PURE__*/function (_Component) {
|
|
|
87
87
|
var _super = _createSuper(CalendarHeader);
|
|
88
88
|
|
|
89
89
|
function CalendarHeader() {
|
|
90
|
-
var _this;
|
|
90
|
+
var _temp, _this;
|
|
91
91
|
|
|
92
92
|
_classCallCheck(this, CalendarHeader);
|
|
93
93
|
|
|
@@ -95,7 +95,7 @@ var CalendarHeader = /*#__PURE__*/function (_Component) {
|
|
|
95
95
|
args[_key] = arguments[_key];
|
|
96
96
|
}
|
|
97
97
|
|
|
98
|
-
return _possibleConstructorReturn(_this, (_this = _super.call.apply(_super, [this].concat(args)), _this.setDate = function (func) {
|
|
98
|
+
return _possibleConstructorReturn(_this, (_temp = _this = _super.call.apply(_super, [this].concat(args)), _this.setDate = function (func) {
|
|
99
99
|
var date = (0, _moment["default"])(_this.props.date);
|
|
100
100
|
|
|
101
101
|
for (var _len2 = arguments.length, rest = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
|
|
@@ -113,7 +113,7 @@ var CalendarHeader = /*#__PURE__*/function (_Component) {
|
|
|
113
113
|
}
|
|
114
114
|
|
|
115
115
|
return years;
|
|
116
|
-
},
|
|
116
|
+
}, _temp));
|
|
117
117
|
}
|
|
118
118
|
|
|
119
119
|
_createClass(CalendarHeader, [{
|
|
@@ -49,7 +49,7 @@ var ConfirmPop = /*#__PURE__*/function (_PureComponent) {
|
|
|
49
49
|
var _super = _createSuper(ConfirmPop);
|
|
50
50
|
|
|
51
51
|
function ConfirmPop() {
|
|
52
|
-
var _this;
|
|
52
|
+
var _temp, _this;
|
|
53
53
|
|
|
54
54
|
_classCallCheck(this, ConfirmPop);
|
|
55
55
|
|
|
@@ -57,13 +57,13 @@ var ConfirmPop = /*#__PURE__*/function (_PureComponent) {
|
|
|
57
57
|
args[_key] = arguments[_key];
|
|
58
58
|
}
|
|
59
59
|
|
|
60
|
-
return _possibleConstructorReturn(_this, (_this = _super.call.apply(_super, [this].concat(args)), _this.handleShowPop = function () {
|
|
60
|
+
return _possibleConstructorReturn(_this, (_temp = _this = _super.call.apply(_super, [this].concat(args)), _this.handleShowPop = function () {
|
|
61
61
|
// @ts-ignore
|
|
62
62
|
_this.refs.pop.show(_this.refs.trigger);
|
|
63
63
|
}, _this.handleHide = function () {
|
|
64
64
|
// @ts-ignore
|
|
65
65
|
_this.refs.pop.hide();
|
|
66
|
-
},
|
|
66
|
+
}, _temp));
|
|
67
67
|
}
|
|
68
68
|
|
|
69
69
|
_createClass(ConfirmPop, [{
|
|
@@ -18,14 +18,12 @@ var _popup = _interopRequireDefault(require("../popup"));
|
|
|
18
18
|
|
|
19
19
|
var _checkbox = _interopRequireDefault(require("../checkbox"));
|
|
20
20
|
|
|
21
|
-
var _radio = _interopRequireDefault(require("../radio"));
|
|
22
|
-
|
|
23
21
|
require("./index.css");
|
|
24
22
|
|
|
25
23
|
var _iconItem = _interopRequireDefault(require("./icon-item"));
|
|
26
24
|
|
|
27
25
|
var _excluded = ["name", "multi", "children", "onClick", "className"],
|
|
28
|
-
_excluded2 = ["trigger", "triggerIcon", "destroyPopupOnHide", "popupPlacement", "hideOnChange", "onChange", "canEdit"];
|
|
26
|
+
_excluded2 = ["trigger", "triggerIcon", "destroyPopupOnHide", "popupPlacement", "hideOnChange", "onChange", "canEdit", "popAction", "onPopupVisibleChange"];
|
|
29
27
|
|
|
30
28
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
31
29
|
|
|
@@ -57,7 +55,7 @@ function _objectWithoutProperties(source, excluded) { if (source == null) return
|
|
|
57
55
|
|
|
58
56
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
59
57
|
|
|
60
|
-
var preCls =
|
|
58
|
+
var preCls = 'titaui-drop-selector';
|
|
61
59
|
var IconItem = _iconItem["default"];
|
|
62
60
|
exports.IconItem = IconItem;
|
|
63
61
|
|
|
@@ -98,7 +96,7 @@ function DropSelectorLayer(props) {
|
|
|
98
96
|
var _classNames;
|
|
99
97
|
|
|
100
98
|
var _props$className = props.className,
|
|
101
|
-
className = _props$className === void 0 ?
|
|
99
|
+
className = _props$className === void 0 ? '' : _props$className,
|
|
102
100
|
_props$multi = props.multi,
|
|
103
101
|
multi = _props$multi === void 0 ? false : _props$multi,
|
|
104
102
|
onItemClick = props.onItemClick,
|
|
@@ -135,12 +133,15 @@ function DropSelector(props) {
|
|
|
135
133
|
_props$destroyPopupOn = props.destroyPopupOnHide,
|
|
136
134
|
destroyPopupOnHide = _props$destroyPopupOn === void 0 ? true : _props$destroyPopupOn,
|
|
137
135
|
_props$popupPlacement = props.popupPlacement,
|
|
138
|
-
popupPlacement = _props$popupPlacement === void 0 ?
|
|
136
|
+
popupPlacement = _props$popupPlacement === void 0 ? 'bottom' : _props$popupPlacement,
|
|
139
137
|
_props$hideOnChange = props.hideOnChange,
|
|
140
138
|
hideOnChange = _props$hideOnChange === void 0 ? true : _props$hideOnChange,
|
|
141
139
|
onChange = props.onChange,
|
|
142
140
|
_props$canEdit = props.canEdit,
|
|
143
141
|
canEdit = _props$canEdit === void 0 ? true : _props$canEdit,
|
|
142
|
+
_props$popAction = props.popAction,
|
|
143
|
+
popAction = _props$popAction === void 0 ? ['click'] : _props$popAction,
|
|
144
|
+
onPopupVisibleChange = props.onPopupVisibleChange,
|
|
144
145
|
restProps = _objectWithoutProperties(props, _excluded2);
|
|
145
146
|
|
|
146
147
|
var _useState3 = (0, _react.useState)(false),
|
|
@@ -148,6 +149,21 @@ function DropSelector(props) {
|
|
|
148
149
|
visible = _useState4[0],
|
|
149
150
|
setVisible = _useState4[1];
|
|
150
151
|
|
|
152
|
+
var realVisible = visible;
|
|
153
|
+
|
|
154
|
+
if ('visible' in props) {
|
|
155
|
+
realVisible = props.visible;
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
var handlePopVisibleChange = (0, _react.useCallback)(function (visible) {
|
|
159
|
+
console.log('visible' in props);
|
|
160
|
+
|
|
161
|
+
if (!('visible' in props)) {
|
|
162
|
+
setVisible(visible);
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
onPopupVisibleChange === null || onPopupVisibleChange === void 0 ? void 0 : onPopupVisibleChange(visible);
|
|
166
|
+
}, [props.visible === undefined]);
|
|
151
167
|
(0, _react.useEffect)(function () {
|
|
152
168
|
setVisible(props.visible);
|
|
153
169
|
}, [props.visible]);
|
|
@@ -161,12 +177,11 @@ function DropSelector(props) {
|
|
|
161
177
|
};
|
|
162
178
|
|
|
163
179
|
return /*#__PURE__*/_react["default"].createElement(_popup["default"], {
|
|
164
|
-
popupVisible: canEdit &&
|
|
180
|
+
popupVisible: canEdit && realVisible,
|
|
165
181
|
popupPlacement: popupPlacement,
|
|
166
|
-
onPopupVisibleChange:
|
|
167
|
-
return setVisible(visible);
|
|
168
|
-
},
|
|
182
|
+
onPopupVisibleChange: handlePopVisibleChange,
|
|
169
183
|
destroyPopupOnHide: destroyPopupOnHide,
|
|
184
|
+
action: popAction,
|
|
170
185
|
popup: /*#__PURE__*/_react["default"].createElement(DropSelectorLayer, _extends({}, restProps, {
|
|
171
186
|
onItemClick: onMenuClickHandler
|
|
172
187
|
}))
|
|
@@ -12,19 +12,19 @@ var _ObjTypeMapText;
|
|
|
12
12
|
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; }
|
|
13
13
|
|
|
14
14
|
var OkrRiskMapping = {
|
|
15
|
-
0:
|
|
15
|
+
0: 'normal',
|
|
16
16
|
// 正常推进
|
|
17
|
-
1:
|
|
17
|
+
1: 'normal',
|
|
18
18
|
// 正常推进
|
|
19
|
-
2:
|
|
19
|
+
2: 'risk',
|
|
20
20
|
// 注意风险
|
|
21
|
-
3:
|
|
21
|
+
3: 'delay',
|
|
22
22
|
// 已有风险
|
|
23
|
-
4:
|
|
23
|
+
4: 'end',
|
|
24
24
|
// kr及o全都完成
|
|
25
|
-
5:
|
|
25
|
+
5: 'delay',
|
|
26
26
|
// 延期完成
|
|
27
|
-
6:
|
|
27
|
+
6: 'normal' // 正常推进
|
|
28
28
|
|
|
29
29
|
};
|
|
30
30
|
exports.OkrRiskMapping = OkrRiskMapping;
|
|
@@ -54,7 +54,7 @@ exports.EFeedType = EFeedType;
|
|
|
54
54
|
EFeedType[EFeedType["Signin"] = 80] = "Signin";
|
|
55
55
|
EFeedType[EFeedType["O"] = 101] = "O";
|
|
56
56
|
EFeedType[EFeedType["OKRsCommunication"] = 102] = "OKRsCommunication";
|
|
57
|
-
EFeedType[EFeedType["
|
|
57
|
+
EFeedType[EFeedType["Interview"] = 103] = "Interview";
|
|
58
58
|
})(EFeedType || (exports.EFeedType = EFeedType = {}));
|
|
59
59
|
|
|
60
60
|
var EShareType;
|
|
@@ -80,37 +80,37 @@ exports.EObjType = EObjType;
|
|
|
80
80
|
EObjType[EObjType["Report"] = 8] = "Report";
|
|
81
81
|
})(EObjType || (exports.EObjType = EObjType = {}));
|
|
82
82
|
|
|
83
|
-
var ObjTypeMapText = (_ObjTypeMapText = {}, _defineProperty(_ObjTypeMapText, EObjType.Project, (0, _getLocale.getLocale)(
|
|
83
|
+
var ObjTypeMapText = (_ObjTypeMapText = {}, _defineProperty(_ObjTypeMapText, EObjType.Project, (0, _getLocale.getLocale)('Menu_Title_Projects')), _defineProperty(_ObjTypeMapText, EObjType.Task, (0, _getLocale.getLocale)('Mod_Tasks')), _defineProperty(_ObjTypeMapText, EObjType.O, (0, _getLocale.getLocale)('Mod_Objective')), _defineProperty(_ObjTypeMapText, EObjType.Kr, (0, _getLocale.getLocale)('Mod_KeyResults')), _defineProperty(_ObjTypeMapText, EObjType.MileStone, (0, _getLocale.getLocale)('Pro_page_Plan_Milestone')), _defineProperty(_ObjTypeMapText, EObjType.KanBan, (0, _getLocale.getLocale)('Pro_page_V_Tab_Kanban')), _defineProperty(_ObjTypeMapText, EObjType.Report, '总结'), _ObjTypeMapText);
|
|
84
84
|
exports.ObjTypeMapText = ObjTypeMapText;
|
|
85
85
|
|
|
86
86
|
var ObjectType = function ObjectType() {
|
|
87
87
|
return {
|
|
88
|
-
1: (0, _getLocale.getLocale)(
|
|
89
|
-
4: (0, _getLocale.getLocale)(
|
|
90
|
-
5: (0, _getLocale.getLocale)(
|
|
91
|
-
6: (0, _getLocale.getLocale)(
|
|
92
|
-
7: (0, _getLocale.getLocale)(
|
|
93
|
-
8: (0, _getLocale.getLocale)(
|
|
94
|
-
10: (0, _getLocale.getLocale)(
|
|
95
|
-
11: (0, _getLocale.getLocale)(
|
|
96
|
-
12: (0, _getLocale.getLocale)(
|
|
97
|
-
62: (0, _getLocale.getLocale)(
|
|
98
|
-
65: (0, _getLocale.getLocale)(
|
|
99
|
-
70: (0, _getLocale.getLocale)(
|
|
100
|
-
79: (0, _getLocale.getLocale)(
|
|
101
|
-
80: (0, _getLocale.getLocale)(
|
|
102
|
-
42: (0, _getLocale.getLocale)(
|
|
88
|
+
1: (0, _getLocale.getLocale)('Mod_sannouncement'),
|
|
89
|
+
4: (0, _getLocale.getLocale)('Menu_Title_Projects'),
|
|
90
|
+
5: (0, _getLocale.getLocale)('Mod_sPerformanceForm'),
|
|
91
|
+
6: (0, _getLocale.getLocale)('Mod_sPerformanceGoals'),
|
|
92
|
+
7: (0, _getLocale.getLocale)('Mod_stasks'),
|
|
93
|
+
8: (0, _getLocale.getLocale)('Mod_sDailySummary'),
|
|
94
|
+
10: (0, _getLocale.getLocale)('Feed_sFeed'),
|
|
95
|
+
11: (0, _getLocale.getLocale)('Pro_page_Plan'),
|
|
96
|
+
12: (0, _getLocale.getLocale)('Feed_OperationTasks'),
|
|
97
|
+
62: (0, _getLocale.getLocale)('Mod_sobjective'),
|
|
98
|
+
65: (0, _getLocale.getLocale)('Feed_Keyresults'),
|
|
99
|
+
70: (0, _getLocale.getLocale)('OKR_MyO_KRP_Review'),
|
|
100
|
+
79: (0, _getLocale.getLocale)('Mod_skeyprogress'),
|
|
101
|
+
80: (0, _getLocale.getLocale)('Feed_sAnnouncement'),
|
|
102
|
+
42: (0, _getLocale.getLocale)('OKR_MyO_E_Reward')
|
|
103
103
|
};
|
|
104
104
|
};
|
|
105
105
|
|
|
106
106
|
exports.ObjectType = ObjectType;
|
|
107
107
|
var EStatusStatus2ClassType = {
|
|
108
|
-
2:
|
|
109
|
-
1:
|
|
110
|
-
4:
|
|
111
|
-
3:
|
|
112
|
-
6:
|
|
113
|
-
0:
|
|
114
|
-
5:
|
|
108
|
+
2: 'tu-icon-finished',
|
|
109
|
+
1: 'tu-icon-running',
|
|
110
|
+
4: 'tu-icon-canceled',
|
|
111
|
+
3: 'tu-icon-deferred',
|
|
112
|
+
6: 'tu-icon-paused',
|
|
113
|
+
0: 'tu-icon-notstart',
|
|
114
|
+
5: 'tu-icon-jiantou-right'
|
|
115
115
|
};
|
|
116
116
|
exports.EStatusStatus2ClassType = EStatusStatus2ClassType;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<svg width="26px" height="21px" viewBox="0 0 26 21" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
|
3
|
+
<title>wife</title>
|
|
4
|
+
<g id="面谈" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
|
|
5
|
+
<g id="5-面谈详情页" transform="translate(-106.000000, -17.000000)" fill="#2879FF" fill-rule="nonzero">
|
|
6
|
+
<g id="面谈人员" transform="translate(58.000000, 8.000000)">
|
|
7
|
+
<g id="wife" transform="translate(48.000000, 9.000000)">
|
|
8
|
+
<g id="编组-7">
|
|
9
|
+
<path d="M12.9658057,9.52816561 C12.2775701,9.52816561 11.7154472,10.0876457 11.7154472,10.7794706 C11.7154472,11.4687707 12.2775701,12.0281656 12.9658057,12.0281656 C13.6566846,12.0281656 14.2150114,11.4687707 14.2150114,10.7794706 C14.2150114,10.0876456 13.6567127,9.52816561 12.9658057,9.52816561 Z" id="路径" transform="translate(12.965229, 10.778166) scale(-1, 1) rotate(-270.000000) translate(-12.965229, -10.778166) "></path>
|
|
10
|
+
<path d="M9.13463077,9.00453638 C7.22941357,9.00453638 5.46172542,9.94655067 4.4067363,11.531305 C4.21117005,11.8188062 4.28841241,12.2143692 4.56884115,12.4134588 C4.67951673,12.488903 4.8030426,12.5227718 4.92136651,12.5227718 C5.12207849,12.5227718 5.31891006,12.4238384 5.44114247,12.2443421 C6.26193014,11.0108739 7.64371594,10.2770207 9.13463077,10.2770207 C10.6051595,10.2770207 11.975276,10.9978496 12.7974415,12.1987571 C12.9930077,12.488903 13.3866146,12.5578919 13.6696865,12.3562145 C13.9527303,12.1584046 14.019625,11.7576376 13.8202346,11.4714161 C12.766567,9.92573457 11.0116729,9.00453638 9.13463077,9.00453638 Z" id="路径" opacity="0.75" transform="translate(9.116567, 10.763654) scale(-1, 1) rotate(-270.000000) translate(-9.116567, -10.763654) "></path>
|
|
11
|
+
<path d="M6.05410015,8.5147913 C3.20198248,8.5147913 0.543996987,9.78992023 -1.2301585,12.0095944 C-1.45015998,12.2828485 -1.40899404,12.6836155 -1.13880053,12.9047724 C-0.873780866,13.1272944 -0.480089595,13.0869418 -0.261409722,12.8137162 C1.27472015,10.8919513 3.58023651,9.78733243 6.05410012,9.78733243 C8.52942591,9.78733243 10.8310057,10.8919513 12.3723094,12.8137162 C12.4932483,12.9711167 12.675908,13.0479259 12.8560371,13.0479259 C12.994972,13.0479259 13.1326135,13.0010612 13.2484349,12.9073887 C13.5198937,12.6861749 13.555942,12.2854647 13.3371778,12.0122106 C11.5643439,9.78992023 8.91150413,8.5147913 6.05410015,8.5147913 Z" id="路径" fill-opacity="0.5" transform="translate(6.053981, 10.781599) scale(-1, 1) rotate(-270.000000) translate(-6.053981, -10.781599) "></path>
|
|
12
|
+
<path d="M12.8458611,12.5083657 C10.3885313,9.64071899 6.80164139,8 2.99995194,8 C-0.796479272,8 -4.38722148,9.64069054 -6.84325778,12.5070575 C-7.07222913,12.7724914 -7.0477939,13.1745381 -6.78662652,13.4048234 C-6.52804606,13.6351656 -6.13050251,13.609117 -5.9053553,13.346271 C-3.68352045,10.757054 -0.438836284,9.26858839 2.99992386,9.26858839 C6.43882458,9.26858839 9.6860957,10.757054 11.9040782,13.346271 C12.0301629,13.4894244 12.202503,13.5635889 12.3749556,13.5635889 C12.5190645,13.5635889 12.6708497,13.5128283 12.7866429,13.4048234 C13.0465168,13.1745665 13.0722737,12.7737995 12.8458611,12.5083657 Z" id="路径" fill-opacity="0.25" transform="translate(3.000000, 10.781794) scale(-1, 1) rotate(-270.000000) translate(-3.000000, -10.781794) "></path>
|
|
13
|
+
</g>
|
|
14
|
+
<g id="编组-7" transform="translate(18.500000, 10.500000) scale(-1, 1) translate(-18.500000, -10.500000) translate(11.000000, 0.000000)">
|
|
15
|
+
<path d="M12.9658057,9.52816561 C12.2775701,9.52816561 11.7154472,10.0876457 11.7154472,10.7794706 C11.7154472,11.4687707 12.2775701,12.0281656 12.9658057,12.0281656 C13.6566846,12.0281656 14.2150114,11.4687707 14.2150114,10.7794706 C14.2150114,10.0876456 13.6567127,9.52816561 12.9658057,9.52816561 Z" id="路径" transform="translate(12.965229, 10.778166) scale(-1, 1) rotate(-270.000000) translate(-12.965229, -10.778166) "></path>
|
|
16
|
+
<path d="M9.13463077,9.00453638 C7.22941357,9.00453638 5.46172542,9.94655067 4.4067363,11.531305 C4.21117005,11.8188062 4.28841241,12.2143692 4.56884115,12.4134588 C4.67951673,12.488903 4.8030426,12.5227718 4.92136651,12.5227718 C5.12207849,12.5227718 5.31891006,12.4238384 5.44114247,12.2443421 C6.26193014,11.0108739 7.64371594,10.2770207 9.13463077,10.2770207 C10.6051595,10.2770207 11.975276,10.9978496 12.7974415,12.1987571 C12.9930077,12.488903 13.3866146,12.5578919 13.6696865,12.3562145 C13.9527303,12.1584046 14.019625,11.7576376 13.8202346,11.4714161 C12.766567,9.92573457 11.0116729,9.00453638 9.13463077,9.00453638 Z" id="路径" opacity="0.75" transform="translate(9.116567, 10.763654) scale(-1, 1) rotate(-270.000000) translate(-9.116567, -10.763654) "></path>
|
|
17
|
+
<path d="M6.05410015,8.5147913 C3.20198248,8.5147913 0.543996987,9.78992023 -1.2301585,12.0095944 C-1.45015998,12.2828485 -1.40899404,12.6836155 -1.13880053,12.9047724 C-0.873780866,13.1272944 -0.480089595,13.0869418 -0.261409722,12.8137162 C1.27472015,10.8919513 3.58023651,9.78733243 6.05410012,9.78733243 C8.52942591,9.78733243 10.8310057,10.8919513 12.3723094,12.8137162 C12.4932483,12.9711167 12.675908,13.0479259 12.8560371,13.0479259 C12.994972,13.0479259 13.1326135,13.0010612 13.2484349,12.9073887 C13.5198937,12.6861749 13.555942,12.2854647 13.3371778,12.0122106 C11.5643439,9.78992023 8.91150413,8.5147913 6.05410015,8.5147913 Z" id="路径" fill-opacity="0.5" transform="translate(6.053981, 10.781599) scale(-1, 1) rotate(-270.000000) translate(-6.053981, -10.781599) "></path>
|
|
18
|
+
<path d="M12.8458611,12.5083657 C10.3885313,9.64071899 6.80164139,8 2.99995194,8 C-0.796479272,8 -4.38722148,9.64069054 -6.84325778,12.5070575 C-7.07222913,12.7724914 -7.0477939,13.1745381 -6.78662652,13.4048234 C-6.52804606,13.6351656 -6.13050251,13.609117 -5.9053553,13.346271 C-3.68352045,10.757054 -0.438836284,9.26858839 2.99992386,9.26858839 C6.43882458,9.26858839 9.6860957,10.757054 11.9040782,13.346271 C12.0301629,13.4894244 12.202503,13.5635889 12.3749556,13.5635889 C12.5190645,13.5635889 12.6708497,13.5128283 12.7866429,13.4048234 C13.0465168,13.1745665 13.0722737,12.7737995 12.8458611,12.5083657 Z" id="路径" fill-opacity="0.25" transform="translate(3.000000, 10.781794) scale(-1, 1) rotate(-270.000000) translate(-3.000000, -10.781794) "></path>
|
|
19
|
+
</g>
|
|
20
|
+
</g>
|
|
21
|
+
</g>
|
|
22
|
+
</g>
|
|
23
|
+
</g>
|
|
24
|
+
</svg>
|