@titaui/pc 1.10.6 → 1.10.8-2.beta-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/.eslintrc.js +2 -2
- package/.prettierignore +4 -4
- package/lib/components/book-demo/utils.js +4 -0
- package/lib/components/button/default-button/index.css +10 -4
- package/lib/components/button/default-button/index.js +13 -2
- package/lib/components/change-okr-modal/index.js +6 -2
- package/lib/components/checkbox/index.css +1 -0
- package/lib/components/communication/CommunicationRecord.js +16 -16
- package/lib/components/communication/index.css +16 -15
- package/lib/components/communication/index.js +23 -6
- package/lib/components/communication/style.js +4 -4
- package/lib/components/create-okr-modal/fields/o-new-name.js +31 -21
- package/lib/components/create-okr-modal/fields/okr-parent.js +1 -5
- package/lib/components/create-okr-modal/kr-items/krDatas.js +16 -16
- package/lib/components/{dynamic/components/dangerous-html → dangerous-html}/index.js +0 -0
- package/lib/components/dialog/index.css +4 -1
- package/lib/components/dialog/index.js +1 -1
- package/lib/components/dialog-confirm/index.css +1 -1
- package/lib/components/drawer/index.js +3 -2
- package/lib/components/drawer-manager/index.js +6 -1
- package/lib/components/dynamic/components/first-level-tabs/index.css +12 -2
- package/lib/components/dynamic/components/first-level-tabs/index.js +19 -6
- package/lib/components/dynamic/components/obj-status/index.css +1 -0
- package/lib/components/dynamic/components/obj-status/utils.js +1 -1
- package/lib/components/dynamic/constant.js +12 -2
- package/lib/components/dynamic/dynamic-item/components/feed-operate/index.css +71 -0
- package/lib/components/dynamic/dynamic-item/components/feed-operate/index.js +112 -0
- package/lib/components/dynamic/dynamic-item/components/header/index.css +2 -1
- package/lib/components/dynamic/dynamic-item/components/header/index.js +2 -2
- package/lib/components/dynamic/dynamic-item/dynamic-ai-dialy/index.js +27 -0
- package/lib/components/dynamic/dynamic-item/dynamic-align/index.css +13 -7
- package/lib/components/dynamic/dynamic-item/dynamic-align/index.js +10 -4
- package/lib/components/dynamic/dynamic-item/dynamic-announcement/index.css +1 -1
- package/lib/components/dynamic/dynamic-item/dynamic-assessment/index.css +1 -1
- package/lib/components/dynamic/dynamic-item/dynamic-assessment/index.js +5 -3
- package/lib/components/dynamic/dynamic-item/dynamic-chart/index.css +4 -0
- package/lib/components/dynamic/dynamic-item/dynamic-chart/index.js +102 -0
- package/lib/components/dynamic/dynamic-item/dynamic-chart/utils.js +61 -0
- package/lib/components/dynamic/dynamic-item/dynamic-create-o/index.css +12 -11
- package/lib/components/dynamic/dynamic-item/dynamic-create-o/index.js +8 -5
- package/lib/components/dynamic/dynamic-item/dynamic-kr/index.css +2 -2
- package/lib/components/dynamic/dynamic-item/dynamic-kr/index.js +5 -3
- package/lib/components/dynamic/dynamic-item/{dynamic-share-to-dynamic → dynamic-learning}/img/dynamic-share-course.png +0 -0
- package/lib/components/dynamic/dynamic-item/{dynamic-share-to-dynamic → dynamic-learning}/img/jiantou-right@3x.png +0 -0
- package/lib/components/dynamic/dynamic-item/{dynamic-share-to-dynamic → dynamic-learning}/img/user-photo.png +0 -0
- package/lib/components/dynamic/dynamic-item/{dynamic-share-to-dynamic → dynamic-learning}/index.css +2 -2
- package/lib/components/dynamic/dynamic-item/{dynamic-share-to-dynamic → dynamic-learning}/index.js +6 -5
- package/lib/components/dynamic/dynamic-item/dynamic-milestone/constant.js +9 -2
- package/lib/components/dynamic/dynamic-item/dynamic-milestone/index.css +2 -2
- package/lib/components/dynamic/dynamic-item/dynamic-milestone/index.js +4 -2
- package/lib/components/dynamic/dynamic-item/dynamic-okrs-communication/index.css +1 -1
- package/lib/components/dynamic/dynamic-item/dynamic-plan-communication/index.css +1 -1
- package/lib/components/dynamic/dynamic-item/dynamic-progress/index.css +2 -6
- package/lib/components/dynamic/dynamic-item/dynamic-progress/index.js +8 -6
- package/lib/components/dynamic/dynamic-item/dynamic-project/index.css +2 -2
- package/lib/components/dynamic/dynamic-item/dynamic-project/index.js +3 -1
- package/lib/components/dynamic/dynamic-item/dynamic-relative/index.css +13 -7
- package/lib/components/dynamic/dynamic-item/dynamic-relative/index.js +42 -6
- package/lib/components/dynamic/dynamic-item/{dynamic-replay → dynamic-reply}/index.css +14 -30
- package/lib/components/dynamic/dynamic-item/{dynamic-replay → dynamic-reply}/index.js +1 -1
- package/lib/components/dynamic/dynamic-item/dynamic-report/index.css +1 -1
- package/lib/components/dynamic/dynamic-item/dynamic-report/index.js +12 -3
- package/lib/components/dynamic/dynamic-item/dynamic-reward/img/reward.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-reward/index.css +6 -1
- package/lib/components/dynamic/dynamic-item/dynamic-reward/index.js +18 -51
- package/lib/components/dynamic/dynamic-item/dynamic-reward/utils.js +28 -0
- package/lib/components/dynamic/dynamic-item/dynamic-share/index.css +6 -2
- package/lib/components/dynamic/dynamic-item/dynamic-share/index.js +55 -2
- package/lib/components/dynamic/dynamic-item/dynamic-task/index.css +2 -2
- package/lib/components/dynamic/dynamic-item/dynamic-task/index.js +1 -1
- package/lib/components/dynamic/dynamic-item/index.css +58 -3
- package/lib/components/dynamic/dynamic-item/index.js +124 -23
- package/lib/components/dynamic/dynamic-like-ranking/item.js +1 -1
- package/lib/components/dynamic/dynamic-list/index.js +11 -2
- package/lib/components/dynamic/dynamic-topping/item.js +8 -4
- package/lib/components/dynamic/dynamic.js +5 -2
- package/lib/components/dynamic/img/dynamic-operate.png +0 -0
- package/lib/components/dynamic/img/dynamic-point.svg +13 -0
- package/lib/components/dynamic/img/dynamic-reward-hover.svg +1 -0
- package/lib/components/dynamic/img/dynamic-reward-normal.svg +1 -0
- package/lib/components/dynamic/online-broadcast/data.js +13 -1
- package/lib/components/e-status-dropdown/index.css +3 -0
- package/lib/components/e-status-dropdown/index.js +94 -0
- package/lib/components/edit-kr-wight/style/index.js +2 -2
- package/lib/components/file-list/components/single-file/index.css +6 -5
- package/lib/components/file-list/components/single-file/index.js +1 -1
- package/lib/components/file-list/index.css +1 -0
- package/lib/components/follower-visitor/index.js +6 -4
- package/lib/components/grid-layout/okr-progress/index.js +20 -30
- package/lib/components/help-card/image/not-try.png +0 -0
- package/lib/components/help-card/image/try.png +0 -0
- package/lib/components/help-card/index.css +31 -2
- package/lib/components/help-card/index.js +54 -17
- package/lib/components/invite-people/img/invite-people.svg +62 -0
- package/lib/components/invite-people/index.css +1 -1
- package/lib/components/mblog/index.js +14 -5
- package/lib/components/menus/export-modules/demo-menus/index.js +2 -2
- package/lib/components/menus/export-modules/demo-menus/menu-highlight.js +25 -1
- package/lib/components/menus/export-modules/demo-menus/menus.js +60 -11
- package/lib/components/menus/export-modules/manage-menus/constant.js +1 -1
- package/lib/components/menus/export-modules/manage-menus/index.css +3 -0
- package/lib/components/menus/export-modules/okr-menus/subordinate-menus/index.js +34 -12
- package/lib/components/menus/images/okr-gongsi.svg +17 -0
- package/lib/components/nav-top/components/menu/index.css +24 -0
- package/lib/components/nav-top/components/menu/index.js +9 -1
- package/lib/components/nav-top/components/user-message/components/reply/index.js +9 -8
- package/lib/components/nav-top/components/user-message/components/reply/reply-item.js +15 -5
- package/lib/components/nav-top/components/user-message/index.css +4 -3
- package/lib/components/nav-top/components/user-message/index.js +33 -6
- package/lib/components/nav-top/request.apis.js +22 -8
- package/lib/components/nav-top/useGlobalValue.js +14 -0
- package/lib/components/okr-detail/components/header/o-name.js +11 -4
- package/lib/components/okr-detail/components/header/o-score.js +4 -6
- package/lib/components/okr-detail/components/okr-tree/tree-node/e-kr-node/index.css +26 -12
- package/lib/components/okr-detail/components/okr-tree/tree-node/e-kr-node/index.js +11 -5
- package/lib/components/okr-detail/components/okr-tree/tree-node/e-node/e-project.js +20 -7
- package/lib/components/okr-detail/components/okr-tree/tree-node/e-node/e-task-level2.js +3 -1
- package/lib/components/okr-detail/components/okr-tree/tree-node/e-node/e-task.js +27 -6
- package/lib/components/okr-detail/components/okr-tree/tree-node/e-node/index.css +29 -10
- package/lib/components/okr-detail/components/okr-tree/tree-node/kr-node/index.js +1 -1
- package/lib/components/okr-detail/detail-header/actions.js +40 -44
- package/lib/components/okr-detail/detail-header/index.css +2 -2
- package/lib/components/okr-detail/detail-header/index.js +207 -195
- package/lib/components/okr-detail/e-list/index.js +70 -24
- package/lib/components/okr-detail/e-list/util.js +11 -2
- package/lib/components/okr-detail/index.js +4 -0
- package/lib/components/okr-detail/okr-list/index.js +1 -5
- package/lib/components/okr-flow/export-modal/index.js +3 -3
- package/lib/components/okr-flow/root-node/index.js +14 -1
- package/lib/components/okr-progress-detail/index.css +11 -10
- package/lib/components/okr-progress-detail/index.js +5 -1
- package/lib/components/okr-progress-detail/utils.js +4 -4
- package/lib/components/okr-progress-modal/helper.js +20 -27
- package/lib/components/okr-share/common-painter/openDataPainter.js +34 -27
- package/lib/components/okrcase-library/okrcases-components/submitOkr-dialog.js +40 -36
- package/lib/components/open-data-painter/index.js +5 -1
- package/lib/components/progress/circle-progress/index.js +1 -1
- package/lib/components/rich-editor/basic/schema.js +47 -0
- package/lib/components/rich-editor/consts/events.js +12 -0
- package/lib/components/rich-editor/enums.js +42 -0
- package/lib/components/rich-editor/index.js +58 -0
- package/lib/components/rich-editor/keymap.js +119 -0
- package/lib/components/rich-editor/keymaps/index.js +241 -0
- package/lib/components/rich-editor/models/controller.js +18 -0
- package/lib/components/rich-editor/models/editor.js +47 -0
- package/lib/components/rich-editor/models/plugin.js +20 -0
- package/lib/components/rich-editor/models/schema.js +121 -0
- package/lib/components/rich-editor/plugins/block/block-quote/commond.js +27 -0
- package/lib/components/rich-editor/plugins/block/block-quote/index.js +128 -0
- package/lib/components/rich-editor/plugins/block/heading/commonds.js +31 -0
- package/lib/components/rich-editor/plugins/block/heading/index.js +190 -0
- package/lib/components/rich-editor/plugins/block/index.js +57 -0
- package/lib/components/rich-editor/plugins/block/lists/actions/conversions.js +172 -0
- package/lib/components/rich-editor/plugins/block/lists/actions/indent-list-items-selected.js +163 -0
- package/lib/components/rich-editor/plugins/block/lists/actions/indent-list.js +59 -0
- package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-forward.js +74 -0
- package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-scenarios/index.js +45 -0
- package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-scenarios/join-list-item-with-paragraph.js +104 -0
- package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-scenarios/join-list-item-with-parent-nested-list.js +92 -0
- package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-scenarios/join-nested-list-with-parent-list-item.js +89 -0
- package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-scenarios/join-paragraph-with-list.js +48 -0
- package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-scenarios/join-sibling-list-items.js +61 -0
- package/lib/components/rich-editor/plugins/block/lists/actions/merge-lists.js +34 -0
- package/lib/components/rich-editor/plugins/block/lists/actions/outdent-list-items-selected.js +289 -0
- package/lib/components/rich-editor/plugins/block/lists/actions/wrap-and-join-lists.js +180 -0
- package/lib/components/rich-editor/plugins/block/lists/baseCommand.js +328 -0
- package/lib/components/rich-editor/plugins/block/lists/commond/indent-list.js +60 -0
- package/lib/components/rich-editor/plugins/block/lists/commond/index.js +396 -0
- package/lib/components/rich-editor/plugins/block/lists/commond/join-list-item-forward.js +45 -0
- package/lib/components/rich-editor/plugins/block/lists/commond/listBackspace.js +302 -0
- package/lib/components/rich-editor/plugins/block/lists/commond/outdent-list.js +43 -0
- package/lib/components/rich-editor/plugins/block/lists/index.js +224 -0
- package/lib/components/rich-editor/plugins/block/lists/messages.js +38 -0
- package/lib/components/rich-editor/plugins/block/lists/pm-plugins/input-rule.js +152 -0
- package/lib/components/rich-editor/plugins/block/lists/pm-plugins/keymap.js +33 -0
- package/lib/components/rich-editor/plugins/block/lists/pm-plugins/main.js +94 -0
- package/lib/components/rich-editor/plugins/block/lists/styles.js +15 -0
- package/lib/components/rich-editor/plugins/block/lists/transforms.js +347 -0
- package/lib/components/rich-editor/plugins/block/lists/utils/analytics.js +48 -0
- package/lib/components/rich-editor/plugins/block/lists/utils/find.js +126 -0
- package/lib/components/rich-editor/plugins/block/lists/utils/indentation.js +87 -0
- package/lib/components/rich-editor/plugins/block/lists/utils/node.js +144 -0
- package/lib/components/rich-editor/plugins/block/lists/utils/replace-content.js +31 -0
- package/lib/components/rich-editor/plugins/block/lists/utils/selection.js +201 -0
- package/lib/components/rich-editor/plugins/block/lists/utils.js +52 -0
- package/lib/components/rich-editor/plugins/block/paragraph/index.js +91 -0
- package/lib/components/rich-editor/plugins/core/index.js +90 -0
- package/lib/components/rich-editor/plugins/core/pm-plugins/focus-handler.js +67 -0
- package/lib/components/rich-editor/plugins/core/pm-plugins/keymap.js +29 -0
- package/lib/components/rich-editor/plugins/core/pm-plugins/reactNodeView.js +80 -0
- package/lib/components/rich-editor/plugins/extension/alignment/commond.js +24 -0
- package/lib/components/rich-editor/plugins/extension/alignment/index.js +113 -0
- package/lib/components/rich-editor/plugins/extension/alignment/utils.js +19 -0
- package/lib/components/rich-editor/plugins/extension/index.js +18 -0
- package/lib/components/rich-editor/plugins/extension/placeholder/index.js +126 -0
- package/lib/components/rich-editor/plugins/extension/placeholder/styles.js +19 -0
- package/lib/components/rich-editor/plugins/index.js +44 -0
- package/lib/components/rich-editor/plugins/inline/color/commond.js +128 -0
- package/lib/components/rich-editor/plugins/inline/color/consts.js +43 -0
- package/lib/components/rich-editor/plugins/inline/color/index.css +61 -0
- package/lib/components/rich-editor/plugins/inline/color/index.js +217 -0
- package/lib/components/rich-editor/plugins/inline/color/selector.js +252 -0
- package/lib/components/rich-editor/plugins/inline/color/util.js +25 -0
- package/lib/components/rich-editor/plugins/inline/delete-line/index.js +149 -0
- package/lib/components/rich-editor/plugins/inline/em/index.js +93 -0
- package/lib/components/rich-editor/plugins/inline/index.js +83 -0
- package/lib/components/rich-editor/plugins/inline/link/commands.js +256 -0
- package/lib/components/rich-editor/plugins/inline/link/index.js +149 -0
- package/lib/components/rich-editor/plugins/inline/link/pm-plugins/fake-cursor-for-toolbar.js +77 -0
- package/lib/components/rich-editor/plugins/inline/link/pm-plugins/main.js +293 -0
- package/lib/components/rich-editor/plugins/inline/link/ui/index.css +84 -0
- package/lib/components/rich-editor/plugins/inline/link/ui/linkEditor.js +150 -0
- package/lib/components/rich-editor/plugins/inline/link/ui/linkToolbar.js +101 -0
- package/lib/components/rich-editor/plugins/inline/link/ui/toolbarBtn.js +117 -0
- package/lib/components/rich-editor/plugins/inline/link/utils.js +33 -0
- package/lib/components/rich-editor/plugins/inline/strong/index.js +139 -0
- package/lib/components/rich-editor/plugins/inline/under-line/index.js +147 -0
- package/lib/components/rich-editor/plugins/util.js +284 -0
- package/lib/components/rich-editor/react/reactNodeView.js +383 -0
- package/lib/components/rich-editor/react/uiProvider.js +185 -0
- package/lib/components/rich-editor/schemas/basic.js +309 -0
- package/lib/components/rich-editor/schemas/index.js +19 -0
- package/lib/components/rich-editor/schemas/list.js +342 -0
- package/lib/components/rich-editor/types/commond.js +5 -0
- package/lib/components/rich-editor/types/index.js +18 -0
- package/lib/components/rich-editor/ui/Popup/index.js +247 -0
- package/lib/components/rich-editor/ui/Popup/utils.js +399 -0
- package/lib/components/rich-editor/ui/editor/index.css +178 -0
- package/lib/components/rich-editor/ui/editor/index.js +153 -0
- package/lib/components/rich-editor/ui/normal-toolbar/index.css +34 -0
- package/lib/components/rich-editor/ui/normal-toolbar/index.js +109 -0
- package/lib/components/rich-editor/utils/browser.js +35 -0
- package/lib/components/rich-editor/utils/commands.js +266 -0
- package/lib/components/rich-editor/utils/document.js +211 -0
- package/lib/components/rich-editor/utils/event.js +79 -0
- package/lib/components/rich-editor/utils/helpers.js +16 -0
- package/lib/components/rich-editor/utils/mark.js +168 -0
- package/lib/components/rich-editor/utils/slice.js +85 -0
- package/lib/components/rich-editor/utils/toolbar.js +228 -0
- package/lib/components/scrollbar/index.js +67 -9
- package/lib/components/scrollbar/scroll-mask/index.css +29 -0
- package/lib/components/scrollbar/scroll-mask/index.js +152 -0
- package/lib/components/superset-charts/components/chart/index.js +54 -0
- package/lib/components/superset-charts/fetch-assets-and-append/append-assets.js +106 -0
- package/lib/components/superset-charts/fetch-assets-and-append/get-assets-with-cache.js +142 -0
- package/lib/components/superset-charts/fetch-assets-and-append/index.js +79 -0
- package/lib/components/superset-charts/index.js +13 -0
- package/lib/components/superset-charts/interface.js +5 -0
- package/lib/components/superset-charts/utils/axios.js +102 -0
- package/lib/components/toast/index.js +5 -17
- package/lib/components/tree/index.css +3 -2
- package/lib/components/upload/index.js +4 -2
- package/lib/components/upload/util.js +2 -0
- package/lib/components/upload-photo-modal/request-api.js +1 -17
- package/lib/components/user-selector/empty/index.css +6 -6
- package/lib/components/user-selector/selected-panel/index.css +3 -3
- package/lib/components/{float-fixed-video-modal → video-modal/components/video-box}/index.css +118 -121
- package/lib/components/{float-fixed-video-modal → video-modal/components/video-box}/index.js +182 -182
- package/lib/components/{float-fixed-video-modal → video-modal}/img/close.png +0 -0
- package/lib/components/{float-fixed-video-modal → video-modal}/img/full.svg +0 -0
- package/lib/components/video-modal/img/muted.svg +8 -10
- package/lib/components/video-modal/img/not-muted.svg +17 -11
- package/lib/components/video-modal/img/pause.svg +7 -11
- package/lib/components/video-modal/img/play.svg +13 -11
- package/lib/components/video-modal/index.css +38 -168
- package/lib/components/video-modal/index.js +104 -244
- package/lib/components/video-modal/utils.js +2 -2
- package/lib/components/wechat-btn/index.css +10 -0
- package/lib/components/wechat-btn/index.js +232 -0
- package/lib/components/weekly-report/common-painter/openDataPainter.js +5 -1
- package/lib/hooks/useGlobalState.js +63 -0
- package/lib/index.js +39 -7
- package/lib/pages/aha2021/img/canceled.svg +13 -0
- package/lib/pages/aha2021/img/not-try.png +0 -0
- package/lib/pages/aha2021/img/try.png +0 -0
- package/lib/pages/aha2021/index.css +52 -0
- package/lib/pages/aha2021/index.js +73 -14
- package/lib/pages/group-management/tree/group-form/index.js +1 -1
- package/lib/pages/new-okr-list/header/index.js +2 -1
- package/lib/pages/new-okr-list/index.js +10 -13
- package/lib/pages/okr-map/export-modules/share-okr-page/header/index.js +0 -5
- package/lib/pages/pay/image/success.png +0 -0
- package/lib/pages/pay/index.css +79 -0
- package/lib/pages/pay/index.js +66 -0
- package/lib/pages/personal-info/request-api.js +1 -1
- package/lib/utils/auth.js +15 -5
- package/lib/utils/bs-global.js +8 -8
- package/lib/utils/helpers.js +7 -1
- package/lib/utils/open-data.js +82 -2
- package/lib/utils/tools.js +11 -2
- package/package.json +121 -101
- package/lib/components/float-fixed-video-modal/img/muted.svg +0 -21
- package/lib/components/float-fixed-video-modal/img/pause.svg +0 -21
- package/lib/components/float-fixed-video-modal/img/play.svg +0 -22
- package/lib/components/float-fixed-video-modal/img/small.svg +0 -22
- package/lib/components/float-fixed-video-modal/img/smallFaQi.png +0 -0
- package/lib/components/float-fixed-video-modal/img/volume.svg +0 -21
- package/lib/components/float-fixed-video-modal/utils.js +0 -25
- package/lib/components/invite-people/img/invite-people.png +0 -0
- package/lib/components/video-modal/img/play.png +0 -0
|
@@ -154,7 +154,8 @@ function Header(props, ref) {
|
|
|
154
154
|
annualNum: annualNum,
|
|
155
155
|
yqmNum: yqmNum
|
|
156
156
|
})), "rootNode=".concat(JSON.stringify(rootNode)), "level2Selected=".concat(JSON.stringify(level2Selected))].join("&");
|
|
157
|
-
|
|
157
|
+
var origin = window.location.href.split('#')[0];
|
|
158
|
+
window.location.href = "".concat(origin, "/#okr/map?").concat(urlQuery);
|
|
158
159
|
};
|
|
159
160
|
|
|
160
161
|
var getTitle = function getTitle() {
|
|
@@ -178,7 +178,12 @@ var NewOkrList = function NewOkrList(props) {
|
|
|
178
178
|
|
|
179
179
|
(0, _react.useEffect)(function () {
|
|
180
180
|
setPageNum(1);
|
|
181
|
-
}, [relation, toUserId, departmentId, query]);
|
|
181
|
+
}, [relation, toUserId, departmentId, query]);
|
|
182
|
+
(0, _react.useEffect)(function () {
|
|
183
|
+
handleOnSearch({
|
|
184
|
+
keyWords: ""
|
|
185
|
+
});
|
|
186
|
+
}, [relation, toUserId, departmentId]); // 记录访问者数据
|
|
182
187
|
|
|
183
188
|
var recordVisitUser = function recordVisitUser() {
|
|
184
189
|
if (toUserId) {
|
|
@@ -205,21 +210,13 @@ var NewOkrList = function NewOkrList(props) {
|
|
|
205
210
|
params.Searchpage = 2;
|
|
206
211
|
}
|
|
207
212
|
|
|
208
|
-
if (departmentId
|
|
209
|
-
params.keyWords =
|
|
210
|
-
}
|
|
211
|
-
|
|
212
|
-
var request;
|
|
213
|
-
|
|
214
|
-
if (!relation) {
|
|
215
|
-
request = (0, _requestApi.okrSearch)(params);
|
|
216
|
-
} else {
|
|
217
|
-
request = (0, _requestApi.okrList)(params);
|
|
213
|
+
if (departmentId !== 0 && departmentId !== "0") {
|
|
214
|
+
params.keyWords = "";
|
|
218
215
|
}
|
|
219
216
|
|
|
220
217
|
setLoading(true);
|
|
221
218
|
recordVisitUser();
|
|
222
|
-
|
|
219
|
+
(0, _requestApi.okrSearch)(params).then(function (res) {
|
|
223
220
|
setOkrs(res.works || []);
|
|
224
221
|
setTotal(res.total);
|
|
225
222
|
setLoading(false);
|
|
@@ -363,7 +360,7 @@ var NewOkrList = function NewOkrList(props) {
|
|
|
363
360
|
className: "okr-list__check-filter-btn",
|
|
364
361
|
onClick: triggerAnimation
|
|
365
362
|
}, (0, _getLocale.getLocale)("OKR_MyO_Text_Check")), (0, _getLocale.getLocale)("OKR_MyO_Text_Topfiltercriteria")), /*#__PURE__*/_react["default"].createElement(_dialog["default"], {
|
|
366
|
-
zIndex:
|
|
363
|
+
zIndex: 1200,
|
|
367
364
|
noHeadLine: true,
|
|
368
365
|
visible: casesVisible,
|
|
369
366
|
onClose: onCasesCloseHandler,
|
|
@@ -59,11 +59,6 @@ function _default(props) {
|
|
|
59
59
|
return setShowKr(checked);
|
|
60
60
|
}
|
|
61
61
|
})), /*#__PURE__*/_react["default"].createElement("span", {
|
|
62
|
-
className: (0, _classnames["default"])("".concat(_precls["default"], "-share-okr__header-dark")),
|
|
63
|
-
onClick: function onClick() {
|
|
64
|
-
return setDarkTheme(!darkTheme);
|
|
65
|
-
}
|
|
66
|
-
}, "\u5207\u6362", darkTheme ? "浅色" : "深色", "\u6A21\u5F0F"), /*#__PURE__*/_react["default"].createElement("span", {
|
|
67
62
|
className: (0, _classnames["default"])("".concat(_precls["default"], "-share-okr__header-direction"))
|
|
68
63
|
}, /*#__PURE__*/_react["default"].createElement(_iconButtonList["default"], {
|
|
69
64
|
items: iconButtons,
|
|
Binary file
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
.tita-pay-page {
|
|
2
|
+
width: 100vw;
|
|
3
|
+
height: 100vh;
|
|
4
|
+
background: linear-gradient(180deg, #e9f1ff 0%, rgba(233, 241, 255, 0) 100%);
|
|
5
|
+
position: relative;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
.tita-pay-page-layout {
|
|
9
|
+
position: absolute;
|
|
10
|
+
top: calc(50% - 40px);
|
|
11
|
+
left: 50%;
|
|
12
|
+
transform: translate(-50%, -50%);
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.tita-pay-page__title {
|
|
16
|
+
display: flex;
|
|
17
|
+
justify-content: center;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
.tita-pay-page__card {
|
|
21
|
+
width: 444px;
|
|
22
|
+
height: 469px;
|
|
23
|
+
background: #ffffff;
|
|
24
|
+
box-shadow: 0px 12px 20px 0px rgba(127, 145, 180, 0.2);
|
|
25
|
+
border-radius: 24px;
|
|
26
|
+
display: flex;
|
|
27
|
+
flex-direction: column;
|
|
28
|
+
align-items: center;
|
|
29
|
+
margin-top: 21px;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.tita-pay-page__card__success-image {
|
|
33
|
+
width: 194px;
|
|
34
|
+
height: 194px;
|
|
35
|
+
margin-top: 76px;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.tita-pay-page__card__success-message {
|
|
39
|
+
font-weight: 600;
|
|
40
|
+
margin-top: 28px;
|
|
41
|
+
font-size: 20px;
|
|
42
|
+
color: #3f4755;
|
|
43
|
+
line-height: 32px;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.tita-pay-page__card__success-promptMes {
|
|
47
|
+
font-size: 14px;
|
|
48
|
+
font-weight: 400;
|
|
49
|
+
color: #3f4755;
|
|
50
|
+
line-height: 22px;
|
|
51
|
+
margin-top: 12px;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.tita-pay-page__card-title {
|
|
55
|
+
font-size: 20px;
|
|
56
|
+
color: #141c28;
|
|
57
|
+
line-height: 30px;
|
|
58
|
+
margin-top: 44px;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
.tita-pay-page__card-price {
|
|
62
|
+
margin: 12px 0 17px;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
.tita-pay-page__card-qrcode {
|
|
66
|
+
width: 240px;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
.tita-pay-page__card-qrcode > img {
|
|
70
|
+
width: 100%;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
.tita-pay-page__card-promptMes {
|
|
74
|
+
margin-top: 20px;
|
|
75
|
+
font-size: 16px;
|
|
76
|
+
font-weight: 400;
|
|
77
|
+
color: #3f4755;
|
|
78
|
+
line-height: 22px;
|
|
79
|
+
}
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports["default"] = void 0;
|
|
7
|
+
|
|
8
|
+
var _react = _interopRequireDefault(require("react"));
|
|
9
|
+
|
|
10
|
+
var _success = _interopRequireDefault(require("./image/success.png"));
|
|
11
|
+
|
|
12
|
+
require("./index.css");
|
|
13
|
+
|
|
14
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
15
|
+
|
|
16
|
+
var preCls = "tita-pay-page";
|
|
17
|
+
|
|
18
|
+
var payPage = function payPage(_ref) {
|
|
19
|
+
var title = _ref.title,
|
|
20
|
+
cardTitle = _ref.cardTitle,
|
|
21
|
+
price = _ref.price,
|
|
22
|
+
qrcode = _ref.qrcode,
|
|
23
|
+
promptMes = _ref.promptMes,
|
|
24
|
+
isSuccessPay = _ref.isSuccessPay,
|
|
25
|
+
successMes = _ref.successMes;
|
|
26
|
+
|
|
27
|
+
var renderSuccessCard = function renderSuccessCard() {
|
|
28
|
+
return /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, /*#__PURE__*/_react["default"].createElement("img", {
|
|
29
|
+
className: "".concat(preCls, "__card__success-image"),
|
|
30
|
+
src: _success["default"],
|
|
31
|
+
alt: ""
|
|
32
|
+
}), /*#__PURE__*/_react["default"].createElement("div", {
|
|
33
|
+
className: "".concat(preCls, "__card__success-message")
|
|
34
|
+
}, "\u606D\u559C\u60A8\uFF0C\u652F\u4ED8\u6210\u529F"), /*#__PURE__*/_react["default"].createElement("div", {
|
|
35
|
+
className: "".concat(preCls, "__card__success-promptMes")
|
|
36
|
+
}, successMes));
|
|
37
|
+
};
|
|
38
|
+
|
|
39
|
+
var renderCard = function renderCard() {
|
|
40
|
+
return /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, /*#__PURE__*/_react["default"].createElement("div", {
|
|
41
|
+
className: "".concat(preCls, "__card-title")
|
|
42
|
+
}, cardTitle), /*#__PURE__*/_react["default"].createElement("div", {
|
|
43
|
+
className: "".concat(preCls, "__card-price")
|
|
44
|
+
}, price), /*#__PURE__*/_react["default"].createElement("div", {
|
|
45
|
+
className: "".concat(preCls, "__card-qrcode")
|
|
46
|
+
}, /*#__PURE__*/_react["default"].createElement("img", {
|
|
47
|
+
src: qrcode,
|
|
48
|
+
alt: ""
|
|
49
|
+
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
50
|
+
className: "".concat(preCls, "__card-promptMes")
|
|
51
|
+
}, qrcode ? promptMes : "订单获取失败,请返回重试"));
|
|
52
|
+
};
|
|
53
|
+
|
|
54
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
55
|
+
className: "".concat(preCls)
|
|
56
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
57
|
+
className: "".concat(preCls, "-layout")
|
|
58
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
59
|
+
className: "".concat(preCls, "__title")
|
|
60
|
+
}, title), /*#__PURE__*/_react["default"].createElement("div", {
|
|
61
|
+
className: "".concat(preCls, "__card")
|
|
62
|
+
}, isSuccessPay ? renderSuccessCard() : renderCard())));
|
|
63
|
+
};
|
|
64
|
+
|
|
65
|
+
var _default = payPage;
|
|
66
|
+
exports["default"] = _default;
|
|
@@ -21,7 +21,7 @@ exports.getUserInfoFun = getUserInfoFun;
|
|
|
21
21
|
|
|
22
22
|
var saveUserInfo = function saveUserInfo(_ref) {
|
|
23
23
|
var data = _ref.data;
|
|
24
|
-
return (0, _request.rput)("v1")("manage/user/
|
|
24
|
+
return (0, _request.rput)("v1")("manage/user/updatebasic", data, {
|
|
25
25
|
headers: {
|
|
26
26
|
"Content-Type": "application/x-www-form-urlencoded"
|
|
27
27
|
},
|
package/lib/utils/auth.js
CHANGED
|
@@ -92,8 +92,10 @@ var OAuth = /*#__PURE__*/function (_BaseAuth) {
|
|
|
92
92
|
}, {
|
|
93
93
|
key: "isPrincipalUser",
|
|
94
94
|
value: function isPrincipalUser() {
|
|
95
|
+
var _this$principalUser;
|
|
96
|
+
|
|
95
97
|
// console.log('o isp', this.userId, this.principalUser.userId)
|
|
96
|
-
return this.userId == this.principalUser.userId;
|
|
98
|
+
return this.userId == ((_this$principalUser = this.principalUser) === null || _this$principalUser === void 0 ? void 0 : _this$principalUser.userId);
|
|
97
99
|
} // 有操作OKR的權限
|
|
98
100
|
|
|
99
101
|
}, {
|
|
@@ -139,8 +141,10 @@ var KRAuth = /*#__PURE__*/function (_BaseAuth2) {
|
|
|
139
141
|
}, {
|
|
140
142
|
key: "isPrincipalUser",
|
|
141
143
|
value: function isPrincipalUser() {
|
|
144
|
+
var _this$user;
|
|
145
|
+
|
|
142
146
|
// console.log('kr isp', this.userId, this.user.userId)
|
|
143
|
-
return this.userId == this.user.userId;
|
|
147
|
+
return this.userId == ((_this$user = this.user) === null || _this$user === void 0 ? void 0 : _this$user.userId);
|
|
144
148
|
} // 有操作KR的權限
|
|
145
149
|
|
|
146
150
|
}, {
|
|
@@ -178,15 +182,19 @@ var EAuth = /*#__PURE__*/function (_BaseAuth3) {
|
|
|
178
182
|
_createClass(EAuth, [{
|
|
179
183
|
key: "isCreater",
|
|
180
184
|
value: function isCreater() {
|
|
185
|
+
var _this$user2;
|
|
186
|
+
|
|
181
187
|
// console.log('e iscreater', this.userId, this.user.userId)
|
|
182
|
-
return this.userId == this.user.userId;
|
|
188
|
+
return this.userId == ((_this$user2 = this.user) === null || _this$user2 === void 0 ? void 0 : _this$user2.userId);
|
|
183
189
|
} // 負責人
|
|
184
190
|
|
|
185
191
|
}, {
|
|
186
192
|
key: "isPrincipalUser",
|
|
187
193
|
value: function isPrincipalUser() {
|
|
194
|
+
var _this$principalUser2;
|
|
195
|
+
|
|
188
196
|
// console.log('e isp', this.userId, this.principalUser.userId)
|
|
189
|
-
return this.userId == this.principalUser.userId;
|
|
197
|
+
return this.userId == ((_this$principalUser2 = this.principalUser) === null || _this$principalUser2 === void 0 ? void 0 : _this$principalUser2.userId);
|
|
190
198
|
} // 有操作KR的權限
|
|
191
199
|
|
|
192
200
|
}, {
|
|
@@ -268,7 +276,9 @@ var ChildAuth = /*#__PURE__*/function (_BaseAuth5) {
|
|
|
268
276
|
_createClass(ChildAuth, [{
|
|
269
277
|
key: "isPrincipalUser",
|
|
270
278
|
value: function isPrincipalUser() {
|
|
271
|
-
|
|
279
|
+
var _this$principalUser3;
|
|
280
|
+
|
|
281
|
+
return this.userId == ((_this$principalUser3 = this.principalUser) === null || _this$principalUser3 === void 0 ? void 0 : _this$principalUser3.userId);
|
|
272
282
|
} // 超管、助理、目标管理员以及目标负责人可以修改此目标下对齐子目标的权重;
|
|
273
283
|
|
|
274
284
|
}, {
|
package/lib/utils/bs-global.js
CHANGED
|
@@ -95,15 +95,15 @@ exports.formatNum = formatNum;
|
|
|
95
95
|
|
|
96
96
|
var hasWebHead = function hasWebHead(webHeadName) {
|
|
97
97
|
var webHeadMap = {
|
|
98
|
-
task: 1,
|
|
99
|
-
okr: 113,
|
|
100
|
-
project: 112,
|
|
101
|
-
apply: 907,
|
|
102
|
-
kaohe: 403
|
|
98
|
+
task: '1',
|
|
99
|
+
okr: '113',
|
|
100
|
+
project: '112',
|
|
101
|
+
apply: '907',
|
|
102
|
+
kaohe: '403'
|
|
103
103
|
};
|
|
104
|
-
var webHead = window.BSGlobal.
|
|
105
|
-
return webHead.findIndex(function (
|
|
106
|
-
return
|
|
104
|
+
var webHead = window.BSGlobal.WebHead.AppHead;
|
|
105
|
+
return webHead.findIndex(function (a) {
|
|
106
|
+
return a.AppId === webHeadMap[webHeadName];
|
|
107
107
|
}) !== -1;
|
|
108
108
|
};
|
|
109
109
|
|
package/lib/utils/helpers.js
CHANGED
|
@@ -8,7 +8,7 @@ exports.escapeHtml = escapeHtml;
|
|
|
8
8
|
exports.getLoginUserInfo = void 0;
|
|
9
9
|
exports.getTenantInfo = getTenantInfo;
|
|
10
10
|
exports.getUploadMaxSize = getUploadMaxSize;
|
|
11
|
-
exports.isTencentHr = exports.isLocal = exports.isDingDing = void 0;
|
|
11
|
+
exports.isTencentHr = exports.isLocal = exports.isFeishu = exports.isDingDing = void 0;
|
|
12
12
|
|
|
13
13
|
var _bsGlobal = require("./bs-global");
|
|
14
14
|
|
|
@@ -43,6 +43,12 @@ var isDingDing = function isDingDing() {
|
|
|
43
43
|
|
|
44
44
|
exports.isDingDing = isDingDing;
|
|
45
45
|
|
|
46
|
+
var isFeishu = function isFeishu() {
|
|
47
|
+
return getTenantInfo().Source === 862;
|
|
48
|
+
};
|
|
49
|
+
|
|
50
|
+
exports.isFeishu = isFeishu;
|
|
51
|
+
|
|
46
52
|
var isLocal = function isLocal() {
|
|
47
53
|
return !!getTenantInfo().isLocal;
|
|
48
54
|
};
|
package/lib/utils/open-data.js
CHANGED
|
@@ -5,7 +5,7 @@ function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" =
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", {
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
|
-
exports.parseTag = exports.parseString = exports.isWxTrial = exports.isWechat = exports.isPlatform = exports.getSource = exports.getOpenId = exports["default"] = exports.OpenUserName = exports.OpenDepartmentName = void 0;
|
|
8
|
+
exports.parseTag = exports.parseString = exports.parseHtmlAndTextTag = exports.isWxTrial = exports.isWechat = exports.isPlatform = exports.getSource = exports.getOpenId = exports["default"] = exports.OpenUserName = exports.OpenDepartmentName = void 0;
|
|
9
9
|
|
|
10
10
|
var _react = _interopRequireWildcard(require("react"));
|
|
11
11
|
|
|
@@ -178,7 +178,8 @@ var parseTag = function parseTag(str) {
|
|
|
178
178
|
} else {
|
|
179
179
|
openDatas.push( /*#__PURE__*/_react["default"].createElement("span", {
|
|
180
180
|
style: {
|
|
181
|
-
color: "#1890ff"
|
|
181
|
+
color: "#1890ff",
|
|
182
|
+
margin: '0 4px'
|
|
182
183
|
},
|
|
183
184
|
onClick: function onClick(e) {
|
|
184
185
|
return e.stopPropagation();
|
|
@@ -253,6 +254,85 @@ var parseString = function parseString(str) {
|
|
|
253
254
|
};
|
|
254
255
|
|
|
255
256
|
exports.parseString = parseString;
|
|
257
|
+
|
|
258
|
+
var parseHtmlAndTextTag = function parseHtmlAndTextTag(str) {
|
|
259
|
+
var reg = /<\w+[\w\W]*?(userId|departmentId)=["'](\S+?)["'][\w\W]*?>@([\w\W]*?)<\/\w+>/g;
|
|
260
|
+
var strReg = /<\w+[\w\s"'\/=\:\.]*?(?:userId|departmentId)=["']\S+?["'][\w\s"'\/=\:\.]*?>[\w\W]*?<\/\w+?>/;
|
|
261
|
+
var openDatas = [];
|
|
262
|
+
var matchStr = reg.exec(str);
|
|
263
|
+
var openDatareg = /\[(\w+?)\:(\w+?)\]/g;
|
|
264
|
+
var openDataStrReg = /\[\w+?\:\w+?\]/;
|
|
265
|
+
var openDataMatchStr = openDatareg.exec(str);
|
|
266
|
+
|
|
267
|
+
while (matchStr != null || openDataMatchStr != null) {
|
|
268
|
+
if (matchStr) {
|
|
269
|
+
var OpenDataCompoent = matchStr[1] == "userId" ? OpenUserName : OpenDepartmentName;
|
|
270
|
+
|
|
271
|
+
if (!OpenDataCompoent) {
|
|
272
|
+
openDatas.push( /*#__PURE__*/_react["default"].createElement("span", {
|
|
273
|
+
dangerouslySetInnerHTML: {
|
|
274
|
+
__html: matchStr[0]
|
|
275
|
+
},
|
|
276
|
+
onClick: function onClick(e) {
|
|
277
|
+
return e.stopPropagation();
|
|
278
|
+
}
|
|
279
|
+
}));
|
|
280
|
+
} else {
|
|
281
|
+
openDatas.push( /*#__PURE__*/_react["default"].createElement("span", {
|
|
282
|
+
style: {
|
|
283
|
+
color: "#1890ff",
|
|
284
|
+
margin: '0 4px'
|
|
285
|
+
},
|
|
286
|
+
onClick: function onClick(e) {
|
|
287
|
+
return e.stopPropagation();
|
|
288
|
+
}
|
|
289
|
+
}, "@", /*#__PURE__*/_react["default"].createElement(OpenDataCompoent, {
|
|
290
|
+
id: matchStr[2],
|
|
291
|
+
name: matchStr[3]
|
|
292
|
+
})));
|
|
293
|
+
}
|
|
294
|
+
|
|
295
|
+
matchStr = reg.exec(str);
|
|
296
|
+
} else if (openDataMatchStr) {
|
|
297
|
+
var _OpenDataCompoent = openDataMap[openDataMatchStr[2]];
|
|
298
|
+
|
|
299
|
+
if (!_OpenDataCompoent) {
|
|
300
|
+
openDatas.push(openDataMatchStr[0]);
|
|
301
|
+
} else {
|
|
302
|
+
openDatas.push( /*#__PURE__*/_react["default"].createElement("span", null, /*#__PURE__*/_react["default"].createElement(_OpenDataCompoent, {
|
|
303
|
+
id: openDataMatchStr[1]
|
|
304
|
+
})));
|
|
305
|
+
}
|
|
306
|
+
|
|
307
|
+
openDataMatchStr = reg.exec(str);
|
|
308
|
+
}
|
|
309
|
+
}
|
|
310
|
+
|
|
311
|
+
var commonStrs = str.split(strReg);
|
|
312
|
+
var tempStrs = [];
|
|
313
|
+
commonStrs && commonStrs.forEach(function (item) {
|
|
314
|
+
tempStrs.push(item.split(openDataStrReg).filter(function (item) {
|
|
315
|
+
return item !== '';
|
|
316
|
+
}));
|
|
317
|
+
});
|
|
318
|
+
var renderData = [];
|
|
319
|
+
|
|
320
|
+
for (var i = 0; i < tempStrs.length; i++) {
|
|
321
|
+
renderData.push( /*#__PURE__*/_react["default"].createElement("span", {
|
|
322
|
+
style: {
|
|
323
|
+
verticalAlign: 'middle'
|
|
324
|
+
},
|
|
325
|
+
dangerouslySetInnerHTML: {
|
|
326
|
+
__html: tempStrs[i]
|
|
327
|
+
}
|
|
328
|
+
}));
|
|
329
|
+
renderData.push(openDatas[i]);
|
|
330
|
+
}
|
|
331
|
+
|
|
332
|
+
return renderData;
|
|
333
|
+
};
|
|
334
|
+
|
|
335
|
+
exports.parseHtmlAndTextTag = parseHtmlAndTextTag;
|
|
256
336
|
var _default = {
|
|
257
337
|
OpenUserName: OpenUserName,
|
|
258
338
|
OpenDepartmentName: OpenDepartmentName,
|
package/lib/utils/tools.js
CHANGED
|
@@ -10,7 +10,7 @@ exports.htmlDecodeByHtmlRegExp = htmlDecodeByHtmlRegExp;
|
|
|
10
10
|
exports.htmlDecodeByRegExp = htmlDecodeByRegExp;
|
|
11
11
|
exports.htmlEncodeByRegExp = htmlEncodeByRegExp;
|
|
12
12
|
exports.htmlEncodeToHtmlByRegExp = htmlEncodeToHtmlByRegExp;
|
|
13
|
-
exports.unHighLight = exports.openPage = void 0;
|
|
13
|
+
exports.unHighLight = exports.openPage = exports.htmlToText = void 0;
|
|
14
14
|
|
|
15
15
|
var _platform = require("./platform");
|
|
16
16
|
|
|
@@ -274,4 +274,13 @@ function htmlDecodeByHtmlRegExp(str) {
|
|
|
274
274
|
temp = temp.replace(/"/g, "\"");
|
|
275
275
|
temp = temp.replace(/<br\/>/g, "\n");
|
|
276
276
|
return temp;
|
|
277
|
-
}
|
|
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;
|