@shzlx/ui-default 4.58.2
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/README.md +5 -0
- package/api.ts +61 -0
- package/backendlib/builder.ts +182 -0
- package/backendlib/markdown-it-imsize.ts +235 -0
- package/backendlib/markdown-it-katex.ts +139 -0
- package/backendlib/markdown-it-media.ts +163 -0
- package/backendlib/markdown-it-xss.ts +200 -0
- package/backendlib/markdown.js +64 -0
- package/backendlib/misc.ts +54 -0
- package/backendlib/template.ts +279 -0
- package/breakpoints.json +5 -0
- package/components/DOMAttachedObject.ts +128 -0
- package/components/autocomplete/AssignSelectAutoComplete.tsx +22 -0
- package/components/autocomplete/CustomSelectAutoComplete.tsx +23 -0
- package/components/autocomplete/DomainSelectAutoComplete.tsx +18 -0
- package/components/autocomplete/FileSelectAutoComplete.tsx +26 -0
- package/components/autocomplete/LanguageSelectAutoComplete.tsx +24 -0
- package/components/autocomplete/ProblemSelectAutoComplete.tsx +18 -0
- package/components/autocomplete/UserSelectAutoComplete.tsx +23 -0
- package/components/autocomplete/components/AssignSelectAutoComplete.tsx +118 -0
- package/components/autocomplete/components/DomainSelectAutoComplete.tsx +53 -0
- package/components/autocomplete/components/FileSelectAutoComplete.tsx +50 -0
- package/components/autocomplete/components/LanguageSelectAutoComplete.tsx +48 -0
- package/components/autocomplete/components/ProblemSelectAutoComplete.tsx +54 -0
- package/components/autocomplete/components/UserSelectAutoComplete.tsx +54 -0
- package/components/autocomplete/domainselectautocomplete.page.styl +6 -0
- package/components/autocomplete/index.tsx +110 -0
- package/components/autocomplete/problemselectautocomplete.page.styl +6 -0
- package/components/autocomplete/userselectautocomplete.page.styl +6 -0
- package/components/browser-update.page.ts +27 -0
- package/components/calendar/calendar.page.styl +129 -0
- package/components/calendar/index.js +367 -0
- package/components/clipboard.page.ts +23 -0
- package/components/contest/contest.page.styl +119 -0
- package/components/contest/contest.page.ts +23 -0
- package/components/contest/contest_sidebar.page.styl +21 -0
- package/components/contest/problem-contest-bg.png +0 -0
- package/components/contest/problem-contest-bg@2x.png +0 -0
- package/components/customFont.page.tsx +90 -0
- package/components/datepicker/datepicker.page.tsx +94 -0
- package/components/dialog/DomDialog.ts +145 -0
- package/components/dialog/dialog.page.styl +40 -0
- package/components/dialog/index.tsx +285 -0
- package/components/discussion/CommentBox.js +103 -0
- package/components/discussion/collapsible.page.styl +40 -0
- package/components/discussion/collapsible.page.tsx +62 -0
- package/components/discussion/comments.page.styl +142 -0
- package/components/discussion/comments.page.tsx +192 -0
- package/components/discussion/discussion.page.styl +17 -0
- package/components/discussion/history.page.tsx +81 -0
- package/components/discussion/reaction.page.styl +30 -0
- package/components/discussion/reaction.page.tsx +103 -0
- package/components/drop/drop.page.styl +40 -0
- package/components/dropdown/Dropdown.js +50 -0
- package/components/dropdown/dropdown.page.styl +33 -0
- package/components/dropdown/dropdown.page.ts +8 -0
- package/components/editor/cmeditor.page.ts +23 -0
- package/components/editor/cmeditor.styl +10 -0
- package/components/editor/index.tsx +293 -0
- package/components/editor/mdeditor.ts +60 -0
- package/components/editor/textareaHandler.ts +29 -0
- package/components/footer/footer.page.styl +94 -0
- package/components/footer/footer.page.ts +26 -0
- package/components/form/button.page.default.styl +59 -0
- package/components/form/button.page.styl +36 -0
- package/components/form/checkbox.page.styl +89 -0
- package/components/form/form.page.styl +200 -0
- package/components/form/form.page.ts +20 -0
- package/components/form/multiSelectCheckbox.page.js +46 -0
- package/components/form/radiobox.page.styl +62 -0
- package/components/form/select.page.styl +29 -0
- package/components/form/textbox.page.styl +79 -0
- package/components/form/textbox.page.ts +21 -0
- package/components/form/var.inc.styl +14 -0
- package/components/header/header.page.styl +79 -0
- package/components/highlighter/code-example.js +111 -0
- package/components/highlighter/highlighter.page.styl +99 -0
- package/components/highlighter/highlighter.page.ts +72 -0
- package/components/highlighter/meta.js +15 -0
- package/components/highlighter/prismjs.js +122 -0
- package/components/hint.page.styl +9 -0
- package/components/hint.ts +19 -0
- package/components/hitokoto/index.page.js +21 -0
- package/components/hotkey/hotkey.page.js +83 -0
- package/components/katex/katex.page.js +26 -0
- package/components/katex/katex.page.styl +2 -0
- package/components/languageselect.tsx +94 -0
- package/components/loader/loader.page.styl +40 -0
- package/components/mantine.page.tsx +39 -0
- package/components/marker/Marker.js +192 -0
- package/components/marker/MarkerReactive.js +55 -0
- package/components/marker/marker.page.js +8 -0
- package/components/marker/marker.page.styl +57 -0
- package/components/media/media.page.js +46 -0
- package/components/menu/menu-heading.page.js +28 -0
- package/components/menu/menu.page.js +18 -0
- package/components/menu/menu.page.styl +68 -0
- package/components/message/index.page.ts +166 -0
- package/components/message/worker.ts +110 -0
- package/components/messagepad/DialogueListItem.page.styl +28 -0
- package/components/messagepad/DialogueListItemComponent.jsx +39 -0
- package/components/messagepad/Message.page.styl +64 -0
- package/components/messagepad/MessageComponent.jsx +33 -0
- package/components/messagepad/MessagePad.page.styl +99 -0
- package/components/messagepad/MessagePadDialogueContentContainer.jsx +104 -0
- package/components/messagepad/MessagePadDialogueListContainer.jsx +49 -0
- package/components/messagepad/MessagePadInputContainer.jsx +100 -0
- package/components/messagepad/index.jsx +49 -0
- package/components/messagepad/reducers/activeId.ts +36 -0
- package/components/messagepad/reducers/dialogues.js +53 -0
- package/components/messagepad/reducers/index.ts +14 -0
- package/components/messagepad/reducers/inputs.js +43 -0
- package/components/messagepad/reducers/isPosting.ts +49 -0
- package/components/monaco/index.ts +178 -0
- package/components/monaco/languages/markdown.ts +97 -0
- package/components/monaco/languages/typescript.ts +45 -0
- package/components/monaco/languages/yaml.ts +22 -0
- package/components/monaco/loader.ts +96 -0
- package/components/monaco/monaco.styl +30 -0
- package/components/monaco/nls.js +31 -0
- package/components/monaco/schema/problemconfig.ts +123 -0
- package/components/navigation/hamburgers.page.styl +87 -0
- package/components/navigation/nav-logo-small_dark.png +0 -0
- package/components/navigation/navigation.page.js +203 -0
- package/components/navigation/navigation.page.styl +211 -0
- package/components/notification/index.ts +105 -0
- package/components/notification/notification.page.js +14 -0
- package/components/notification/notification.page.styl +84 -0
- package/components/nprogress.page.styl +50 -0
- package/components/omnisearch/index.page.tsx +124 -0
- package/components/omnisearch/omnibar.page.styl +138 -0
- package/components/pager/pager.page.styl +57 -0
- package/components/preview/preview.page.ts +187 -0
- package/components/problem/create.page.js +12 -0
- package/components/problem/list.page.js +9 -0
- package/components/problem/rp.page.styl +4 -0
- package/components/problem/tag.page.styl +84 -0
- package/components/problemconfig/BasicForm.tsx +92 -0
- package/components/problemconfig/ProblemConfigEditor.tsx +170 -0
- package/components/problemconfig/ProblemConfigForm.tsx +140 -0
- package/components/problemconfig/ProblemConfigTree.tsx +163 -0
- package/components/problemconfig/ProblemType.tsx +165 -0
- package/components/problemconfig/index.tsx +91 -0
- package/components/problemconfig/reducer/config.ts +173 -0
- package/components/problemconfig/reducer/index.ts +11 -0
- package/components/problemconfig/reducer/testdata.ts +16 -0
- package/components/problemconfig/tree/AddTestcase.tsx +137 -0
- package/components/problemconfig/tree/SelectionManager.tsx +140 -0
- package/components/problemconfig/tree/SubtaskSettings.tsx +180 -0
- package/components/problemconfig/tree/Testcase.tsx +98 -0
- package/components/profile/backgrounds/1.jpg +0 -0
- package/components/profile/backgrounds/10.jpg +0 -0
- package/components/profile/backgrounds/11.jpg +0 -0
- package/components/profile/backgrounds/12.jpg +0 -0
- package/components/profile/backgrounds/13.jpg +0 -0
- package/components/profile/backgrounds/14.jpg +0 -0
- package/components/profile/backgrounds/15.jpg +0 -0
- package/components/profile/backgrounds/16.jpg +0 -0
- package/components/profile/backgrounds/17.jpg +0 -0
- package/components/profile/backgrounds/18.jpg +0 -0
- package/components/profile/backgrounds/19.jpg +0 -0
- package/components/profile/backgrounds/2.jpg +0 -0
- package/components/profile/backgrounds/20.jpg +0 -0
- package/components/profile/backgrounds/21.jpg +0 -0
- package/components/profile/backgrounds/3.jpg +0 -0
- package/components/profile/backgrounds/4.jpg +0 -0
- package/components/profile/backgrounds/5.jpg +0 -0
- package/components/profile/backgrounds/6.jpg +0 -0
- package/components/profile/backgrounds/7.jpg +0 -0
- package/components/profile/backgrounds/8.jpg +0 -0
- package/components/profile/backgrounds/9.jpg +0 -0
- package/components/profile/backgrounds/gen_thumbnails.sh +7 -0
- package/components/profile/backgrounds/thumbnail/1.jpg +0 -0
- package/components/profile/backgrounds/thumbnail/10.jpg +0 -0
- package/components/profile/backgrounds/thumbnail/11.jpg +0 -0
- package/components/profile/backgrounds/thumbnail/12.jpg +0 -0
- package/components/profile/backgrounds/thumbnail/13.jpg +0 -0
- package/components/profile/backgrounds/thumbnail/14.jpg +0 -0
- package/components/profile/backgrounds/thumbnail/15.jpg +0 -0
- package/components/profile/backgrounds/thumbnail/16.jpg +0 -0
- package/components/profile/backgrounds/thumbnail/17.jpg +0 -0
- package/components/profile/backgrounds/thumbnail/18.jpg +0 -0
- package/components/profile/backgrounds/thumbnail/19.jpg +0 -0
- package/components/profile/backgrounds/thumbnail/2.jpg +0 -0
- package/components/profile/backgrounds/thumbnail/20.jpg +0 -0
- package/components/profile/backgrounds/thumbnail/21.jpg +0 -0
- package/components/profile/backgrounds/thumbnail/3.jpg +0 -0
- package/components/profile/backgrounds/thumbnail/4.jpg +0 -0
- package/components/profile/backgrounds/thumbnail/5.jpg +0 -0
- package/components/profile/backgrounds/thumbnail/6.jpg +0 -0
- package/components/profile/backgrounds/thumbnail/7.jpg +0 -0
- package/components/profile/backgrounds/thumbnail/8.jpg +0 -0
- package/components/profile/backgrounds/thumbnail/9.jpg +0 -0
- package/components/profile/profile.page.styl +23 -0
- package/components/react/DomComponent.tsx +14 -0
- package/components/react/IconComponent.tsx +20 -0
- package/components/record/record.page.styl +26 -0
- package/components/rotator/index.js +75 -0
- package/components/rotator/rotator.page.styl +20 -0
- package/components/scratchpad/DataInput.page.styl +17 -0
- package/components/scratchpad/DataInputComponent.jsx +45 -0
- package/components/scratchpad/Editor.page.styl +13 -0
- package/components/scratchpad/Panel.page.styl +18 -0
- package/components/scratchpad/PanelButton.page.styl +15 -0
- package/components/scratchpad/PanelButtonComponent.jsx +19 -0
- package/components/scratchpad/PanelComponent.jsx +25 -0
- package/components/scratchpad/ScratchpadEditorContainer.tsx +137 -0
- package/components/scratchpad/ScratchpadPretestContainer.jsx +57 -0
- package/components/scratchpad/ScratchpadRecordsContainer.jsx +45 -0
- package/components/scratchpad/ScratchpadRecordsRowContainer.jsx +83 -0
- package/components/scratchpad/ScratchpadSettings.tsx +48 -0
- package/components/scratchpad/ScratchpadToolbarContainer.jsx +190 -0
- package/components/scratchpad/Tab.page.styl +24 -0
- package/components/scratchpad/Toolbar.page.styl +53 -0
- package/components/scratchpad/ToolbarComponent.jsx +85 -0
- package/components/scratchpad/index.tsx +132 -0
- package/components/scratchpad/reducers/editor.ts +24 -0
- package/components/scratchpad/reducers/index.ts +17 -0
- package/components/scratchpad/reducers/pretest.ts +34 -0
- package/components/scratchpad/reducers/records.ts +40 -0
- package/components/scratchpad/reducers/state.ts +10 -0
- package/components/scratchpad/reducers/ui.ts +152 -0
- package/components/scratchpad/scratchpad.page.styl +55 -0
- package/components/scratchpad/var.inc.styl +2 -0
- package/components/selectUser.tsx +16 -0
- package/components/signin/signInDialog.page.js +84 -0
- package/components/signin/signin_dialog.page.styl +57 -0
- package/components/smoothscroll/smoothscroll.page.js +44 -0
- package/components/socket/index.ts +68 -0
- package/components/star/star.page.styl +20 -0
- package/components/star/star.page.ts +58 -0
- package/components/sticky/sticky.page.js +66 -0
- package/components/tab/Tab.js +168 -0
- package/components/tab/tab.page.js +9 -0
- package/components/tab/tab.page.styl +105 -0
- package/components/tab/var.inc.styl +3 -0
- package/components/table/StyledTable.js +51 -0
- package/components/table/styledTable.page.js +8 -0
- package/components/table/table.page.styl +73 -0
- package/components/time/time.page.js +47 -0
- package/components/tooltip/Tooltip.js +49 -0
- package/components/tooltip/tooltip.page.js +29 -0
- package/components/tooltip/tooltip.page.styl +69 -0
- package/components/training/training.page.styl +25 -0
- package/components/upload.tsx +103 -0
- package/components/vote/vote.page.js +43 -0
- package/components/zipDownloader/index.ts +157 -0
- package/constant/domain.js +21 -0
- package/constant/message.js +5 -0
- package/constant/record.js +52 -0
- package/context.ts +11 -0
- package/entry.js +72 -0
- package/hydro.ts +112 -0
- package/index.ts +226 -0
- package/lazyload.ts +69 -0
- package/locales/en.yaml +71 -0
- package/locales/ko.yaml +823 -0
- package/locales/zh.yaml +1137 -0
- package/locales/zh_TW.yaml +1133 -0
- package/misc/Page.ts +49 -0
- package/misc/PageLoader.js +31 -0
- package/misc/float.styl +14 -0
- package/misc/grid.styl +1048 -0
- package/misc/immersive-background.jpg +0 -0
- package/misc/immersive-background@2x.jpg +0 -0
- package/misc/immersive.styl +23 -0
- package/misc/nothing.styl +13 -0
- package/misc/puzzled_twd2.svg +1 -0
- package/misc/section.styl +105 -0
- package/misc/slideout.styl +46 -0
- package/misc/structure.styl +158 -0
- package/misc/textalign.styl +11 -0
- package/misc/typography.styl +485 -0
- package/package.json +148 -0
- package/polyfill.ts +90 -0
- package/postcss.config.js +15 -0
- package/sentry.ts +26 -0
- package/service-worker.ts +265 -0
- package/setting.yaml +98 -0
- package/templates/about.html +14 -0
- package/templates/bsod.html +35 -0
- package/templates/components/comments_discussion.html +165 -0
- package/templates/components/comments_solution.html +171 -0
- package/templates/components/contest.html +12 -0
- package/templates/components/form.html +214 -0
- package/templates/components/home.html +20 -0
- package/templates/components/homework.html +8 -0
- package/templates/components/md_hint.html +39 -0
- package/templates/components/noscript_note.html +15 -0
- package/templates/components/nothing.html +6 -0
- package/templates/components/paginator.html +25 -0
- package/templates/components/problem.html +33 -0
- package/templates/components/record.html +21 -0
- package/templates/components/sidemenu.html +11 -0
- package/templates/components/user.html +49 -0
- package/templates/contest_balloon.html +48 -0
- package/templates/contest_clarification.html +103 -0
- package/templates/contest_detail.html +56 -0
- package/templates/contest_edit.html +259 -0
- package/templates/contest_main.html +146 -0
- package/templates/contest_manage.html +80 -0
- package/templates/contest_print.html +27 -0
- package/templates/contest_problemlist.html +231 -0
- package/templates/contest_scoreboard.html +46 -0
- package/templates/contest_scoreboard_download_html.html +71 -0
- package/templates/contest_user.html +47 -0
- package/templates/discussion_create.html +28 -0
- package/templates/discussion_detail.html +149 -0
- package/templates/discussion_edit.html +30 -0
- package/templates/discussion_main_or_node.html +47 -0
- package/templates/domain_base.html +26 -0
- package/templates/domain_create.html +55 -0
- package/templates/domain_dashboard.html +45 -0
- package/templates/domain_edit.html +6 -0
- package/templates/domain_group.html +51 -0
- package/templates/domain_join.html +47 -0
- package/templates/domain_join_applications.html +67 -0
- package/templates/domain_permission.html +66 -0
- package/templates/domain_role.html +71 -0
- package/templates/domain_user.html +86 -0
- package/templates/domain_user_raw.html +5 -0
- package/templates/error.html +25 -0
- package/templates/home_domain.html +64 -0
- package/templates/home_files.html +16 -0
- package/templates/home_messages.html +9 -0
- package/templates/home_security.html +224 -0
- package/templates/home_settings.html +21 -0
- package/templates/homework_detail.html +82 -0
- package/templates/homework_edit.html +138 -0
- package/templates/homework_files.html +24 -0
- package/templates/homework_main.html +76 -0
- package/templates/layout/basic.html +27 -0
- package/templates/layout/home_base.html +13 -0
- package/templates/layout/html5.html +74 -0
- package/templates/layout/immersive.html +22 -0
- package/templates/layout/mail.html +31 -0
- package/templates/layout/simple.html +4 -0
- package/templates/layout/wiki_base.html +16 -0
- package/templates/main.html +22 -0
- package/templates/manage_base.html +24 -0
- package/templates/manage_config.html +6 -0
- package/templates/manage_dashboard.html +27 -0
- package/templates/manage_script.html +56 -0
- package/templates/manage_setting.html +6 -0
- package/templates/manage_user_import.html +23 -0
- package/templates/manage_user_priv.html +76 -0
- package/templates/partials/category.html +19 -0
- package/templates/partials/contest.html +3 -0
- package/templates/partials/contest_balloon.html +37 -0
- package/templates/partials/contest_sidebar.html +150 -0
- package/templates/partials/contest_sidebar_management.html +56 -0
- package/templates/partials/contest_user.html +19 -0
- package/templates/partials/discussion_edit_form.html +45 -0
- package/templates/partials/discussion_list.html +50 -0
- package/templates/partials/discussion_nodes_widget.html +17 -0
- package/templates/partials/files.html +49 -0
- package/templates/partials/footer.html +108 -0
- package/templates/partials/hamburger.html +7 -0
- package/templates/partials/header_mobile.html +12 -0
- package/templates/partials/homepage/bulletin.html +7 -0
- package/templates/partials/homepage/contest.html +48 -0
- package/templates/partials/homepage/discussion.html +13 -0
- package/templates/partials/homepage/discussion_nodes.html +4 -0
- package/templates/partials/homepage/error.html +5 -0
- package/templates/partials/homepage/hitokoto.html +6 -0
- package/templates/partials/homepage/homework.html +45 -0
- package/templates/partials/homepage/problem_search.html +13 -0
- package/templates/partials/homepage/ranking.html +39 -0
- package/templates/partials/homepage/recent_problems.html +17 -0
- package/templates/partials/homepage/starred_problems.html +15 -0
- package/templates/partials/homepage/suggestion.html +34 -0
- package/templates/partials/homepage/training.html +50 -0
- package/templates/partials/homework.html +3 -0
- package/templates/partials/homework_default_penalty_rules.yaml +6 -0
- package/templates/partials/homework_sidebar.html +93 -0
- package/templates/partials/login_dialog.html +56 -0
- package/templates/partials/manage_user_priv.html +78 -0
- package/templates/partials/nav.html +138 -0
- package/templates/partials/problem-sidebar-information.html +25 -0
- package/templates/partials/problem.html +2 -0
- package/templates/partials/problem_category_dialog.html +43 -0
- package/templates/partials/problem_default.md +26 -0
- package/templates/partials/problem_description.html +33 -0
- package/templates/partials/problem_files.html +63 -0
- package/templates/partials/problem_list.html +68 -0
- package/templates/partials/problem_lucky.html +10 -0
- package/templates/partials/problem_sidebar.html +14 -0
- package/templates/partials/problem_sidebar_contest.html +43 -0
- package/templates/partials/problem_sidebar_homework.html +42 -0
- package/templates/partials/problem_sidebar_normal.html +152 -0
- package/templates/partials/problem_stat.html +3 -0
- package/templates/partials/scoreboard.html +79 -0
- package/templates/partials/setting.html +92 -0
- package/templates/partials/training_default.json +14 -0
- package/templates/partials/training_detail.html +153 -0
- package/templates/partials/user.html +2 -0
- package/templates/partials/user_detail/activity.html +18 -0
- package/templates/partials/user_detail/solution.html +29 -0
- package/templates/problem_config.html +39 -0
- package/templates/problem_detail.html +150 -0
- package/templates/problem_edit.html +111 -0
- package/templates/problem_files.html +91 -0
- package/templates/problem_hack.html +41 -0
- package/templates/problem_import.html +58 -0
- package/templates/problem_main.html +100 -0
- package/templates/problem_solution.html +55 -0
- package/templates/problem_statistics.html +96 -0
- package/templates/problem_submit.html +40 -0
- package/templates/ranking.html +81 -0
- package/templates/record_detail.html +134 -0
- package/templates/record_detail_status.html +93 -0
- package/templates/record_detail_summary.html +19 -0
- package/templates/record_main.html +142 -0
- package/templates/record_main_tr.html +35 -0
- package/templates/status.html +75 -0
- package/templates/training_detail.html +120 -0
- package/templates/training_edit.html +68 -0
- package/templates/training_files.html +64 -0
- package/templates/training_main.html +107 -0
- package/templates/user_changemail_mail.html +6 -0
- package/templates/user_changemail_mail_sent.html +9 -0
- package/templates/user_delete_pending.html +10 -0
- package/templates/user_detail.html +181 -0
- package/templates/user_login.html +46 -0
- package/templates/user_logout.html +13 -0
- package/templates/user_lostpass.html +27 -0
- package/templates/user_lostpass_mail.html +6 -0
- package/templates/user_lostpass_mail_sent.html +9 -0
- package/templates/user_lostpass_with_code.html +29 -0
- package/templates/user_register.html +22 -0
- package/templates/user_register_mail.html +6 -0
- package/templates/user_register_mail_sent.html +9 -0
- package/templates/user_register_with_code.html +35 -0
- package/templates/user_sudo.html +54 -0
- package/templates/user_sudo_redirect.html +18 -0
- package/templates/wiki_help.html +189 -0
- package/theme/bp6-compat.css +48 -0
- package/theme/dark.styl +397 -0
- package/theme/default.js +33 -0
- package/typed.d.ts +20 -0
- package/utils/base.ts +209 -0
- package/utils/base64.js +104 -0
- package/utils/db.ts +32 -0
- package/utils/index.ts +73 -0
- package/utils/loadReactRedux.ts +32 -0
- package/utils/mediaQuery.ts +13 -0
- package/utils/pjax.js +148 -0
- package/utils/slide.ts +57 -0
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
.page-loader
|
|
2
|
+
position: absolute
|
|
3
|
+
top: 0
|
|
4
|
+
left: 0
|
|
5
|
+
right: 0
|
|
6
|
+
bottom: 0
|
|
7
|
+
display: flex
|
|
8
|
+
align-items: center
|
|
9
|
+
justify-content: center
|
|
10
|
+
z-index: 9999
|
|
11
|
+
|
|
12
|
+
.loader-container
|
|
13
|
+
position: absolute
|
|
14
|
+
left: 0
|
|
15
|
+
width: 100%
|
|
16
|
+
top: 0
|
|
17
|
+
height: 100%
|
|
18
|
+
|
|
19
|
+
.loader
|
|
20
|
+
text-indent: -9999em
|
|
21
|
+
border: rem(5px) solid rgba($primary-color, .2)
|
|
22
|
+
border-left: rem(5px) solid $primary-color
|
|
23
|
+
animation: load8 1.1s infinite linear
|
|
24
|
+
border-radius: 50%
|
|
25
|
+
width: rem(50px)
|
|
26
|
+
height: rem(50px)
|
|
27
|
+
margin-left: rem(-25px)
|
|
28
|
+
margin-top: rem(-25px)
|
|
29
|
+
left: 50%
|
|
30
|
+
top: 50%
|
|
31
|
+
position: absolute
|
|
32
|
+
|
|
33
|
+
@keyframes load8
|
|
34
|
+
0%
|
|
35
|
+
transform: rotate(0deg)
|
|
36
|
+
|
|
37
|
+
100%
|
|
38
|
+
transform: rotate(360deg)
|
|
39
|
+
|
|
40
|
+
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { createTheme, Notification as MantineNotification } from '@mantine/core';
|
|
2
|
+
import { AutoloadPage } from 'vj/misc/Page';
|
|
3
|
+
|
|
4
|
+
const colorWhite = {
|
|
5
|
+
color: 'var(--mantine-color-white)',
|
|
6
|
+
} as const;
|
|
7
|
+
|
|
8
|
+
export const theme = createTheme({
|
|
9
|
+
components: {
|
|
10
|
+
Notification: MantineNotification.extend({
|
|
11
|
+
classNames: {
|
|
12
|
+
closeButton: 'mantine-notifications-close-button',
|
|
13
|
+
},
|
|
14
|
+
styles: {
|
|
15
|
+
root: {
|
|
16
|
+
backgroundColor: 'var(--notification-color, var(--mantine-primary-color-filled))',
|
|
17
|
+
paddingInlineStart: 'var(--mantine-spacing-xs)',
|
|
18
|
+
},
|
|
19
|
+
title: {
|
|
20
|
+
...colorWhite,
|
|
21
|
+
fontSize: 'var(--mantine-font-size-md)',
|
|
22
|
+
},
|
|
23
|
+
icon: {
|
|
24
|
+
fontSize: '24px',
|
|
25
|
+
marginInlineEnd: 'var(--mantine-spacing-xs)',
|
|
26
|
+
},
|
|
27
|
+
description: colorWhite,
|
|
28
|
+
closeButton: colorWhite,
|
|
29
|
+
},
|
|
30
|
+
}),
|
|
31
|
+
},
|
|
32
|
+
});
|
|
33
|
+
|
|
34
|
+
export default new AutoloadPage('mantine', null, () => {
|
|
35
|
+
localStorage.setItem(
|
|
36
|
+
'mantine-color-scheme-value',
|
|
37
|
+
document.documentElement.className.includes('theme--dark') ? 'dark' : 'light',
|
|
38
|
+
);
|
|
39
|
+
});
|
|
@@ -0,0 +1,192 @@
|
|
|
1
|
+
import $ from 'jquery';
|
|
2
|
+
import _ from 'lodash';
|
|
3
|
+
import Tooltip from 'vj/components/tooltip/Tooltip';
|
|
4
|
+
import { delay, i18n } from 'vj/utils';
|
|
5
|
+
|
|
6
|
+
const MARKER_ID = `marker_${Math.floor(Math.random() * 0xFFFFFF).toString(16)}`;
|
|
7
|
+
const MARKER_OFFSET = 20;
|
|
8
|
+
const MARKER_MAX_DISTANCE = 60;
|
|
9
|
+
|
|
10
|
+
let markerInstance = null;
|
|
11
|
+
|
|
12
|
+
function distanceToRect(px, py, rect) {
|
|
13
|
+
const cx = (rect.left + rect.right) / 2;
|
|
14
|
+
const cy = (rect.top + rect.bottom) / 2;
|
|
15
|
+
const dx = Math.max(Math.abs(px - cx) - (rect.right - rect.left) / 2, 0);
|
|
16
|
+
const dy = Math.max(Math.abs(py - cy) - (rect.bottom - rect.top) / 2, 0);
|
|
17
|
+
return Math.sqrt(dx * dx + dy * dy);
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
class Marker {
|
|
21
|
+
static exists() {
|
|
22
|
+
return markerInstance && document.getElementById(MARKER_ID);
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
constructor() {
|
|
26
|
+
if (Marker.exists()) return markerInstance;
|
|
27
|
+
if (markerInstance) {
|
|
28
|
+
markerInstance.destroy();
|
|
29
|
+
}
|
|
30
|
+
this.$dom = $(`
|
|
31
|
+
<div class="marker" id="${MARKER_ID}"><div class="marker__toolbar">
|
|
32
|
+
<div class="marker__action" data-color="#ffff00" data-tooltip="${i18n('Mark Yellow')}"><span class="marker__icon icon-yellow"></span></div>
|
|
33
|
+
<div class="marker__action" data-color="#47ff6f" data-tooltip="${i18n('Mark Green')}"><span class="marker__icon icon-green"></span></div>
|
|
34
|
+
<div class="marker__action" data-color="#ff3b30" data-tooltip="${i18n('Mark Red')}"><span class="marker__icon icon-red"></span></div>
|
|
35
|
+
<div class="marker__action" data-color="transparent" data-tooltip="${i18n('Clear Marks')}"><span class="icon icon-erase"></span></div>
|
|
36
|
+
</div></div>
|
|
37
|
+
`)
|
|
38
|
+
.appendTo('body');
|
|
39
|
+
this.$dom.find('.marker__toolbar').on('click', '.marker__action', this.onMarkerActionClick.bind(this));
|
|
40
|
+
this.$dom.on('mousedown', this.onMarkerMouseDown.bind(this));
|
|
41
|
+
this.isOpen = false;
|
|
42
|
+
this.bindedHandlers = false;
|
|
43
|
+
this._onKeyDown = this.onKeyDown.bind(this);
|
|
44
|
+
this._onScroll = _.throttle(this.onScroll.bind(this), 50);
|
|
45
|
+
this._onMouseDown = this.onMouseDown.bind(this);
|
|
46
|
+
this._onMouseMove = _.throttle(this.onMouseMove.bind(this), 50);
|
|
47
|
+
markerInstance = this;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
markSelection(color) {
|
|
51
|
+
const selection = window.getSelection();
|
|
52
|
+
const range = selection.getRangeAt(0);
|
|
53
|
+
this.$container.attr('contentEditable', true);
|
|
54
|
+
if (range) {
|
|
55
|
+
// recover ranges
|
|
56
|
+
selection.removeAllRanges();
|
|
57
|
+
selection.addRange(range);
|
|
58
|
+
}
|
|
59
|
+
if (!document.execCommand('HiliteColor', false, color)) {
|
|
60
|
+
document.execCommand('BackColor', false, color);
|
|
61
|
+
}
|
|
62
|
+
this.$container.removeAttr('contentEditable');
|
|
63
|
+
if (range) {
|
|
64
|
+
// remove ranges after marking
|
|
65
|
+
selection.removeAllRanges();
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
showAtPosition($container, x, y) {
|
|
70
|
+
this.$container = $container;
|
|
71
|
+
this.$dom.css({
|
|
72
|
+
display: 'block',
|
|
73
|
+
opacity: 0,
|
|
74
|
+
});
|
|
75
|
+
const rect = this.$dom[0].getBoundingClientRect();
|
|
76
|
+
this.$dom.css({
|
|
77
|
+
left: x + MARKER_OFFSET,
|
|
78
|
+
top: y - (rect.bottom - rect.top) - MARKER_OFFSET,
|
|
79
|
+
});
|
|
80
|
+
this.isOpen = true;
|
|
81
|
+
this.$dom.addClass('open');
|
|
82
|
+
this.updateMarkerOpacity(x, y);
|
|
83
|
+
this.bindEventHandlersForClosing();
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
async close() {
|
|
87
|
+
if (!this.isOpen) {
|
|
88
|
+
return;
|
|
89
|
+
}
|
|
90
|
+
this.isOpen = false;
|
|
91
|
+
this.closeTooltipsImmediately();
|
|
92
|
+
this.unbindEventHandlers();
|
|
93
|
+
this.$dom
|
|
94
|
+
.css({ opacity: 0 })
|
|
95
|
+
.removeClass('open');
|
|
96
|
+
await delay(200);
|
|
97
|
+
if (!this.isOpen) {
|
|
98
|
+
this.$dom.hide();
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
closeTooltipsImmediately() {
|
|
103
|
+
const $elements = this.$dom.find('[data-tooltip]');
|
|
104
|
+
$elements.get().forEach((element) => {
|
|
105
|
+
const $el = $(element);
|
|
106
|
+
const tooltipInstance = Tooltip.get($el);
|
|
107
|
+
if (tooltipInstance) {
|
|
108
|
+
tooltipInstance.detach();
|
|
109
|
+
}
|
|
110
|
+
});
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
bindEventHandlersForClosing() {
|
|
114
|
+
if (this.bindedHandlers) {
|
|
115
|
+
return;
|
|
116
|
+
}
|
|
117
|
+
$(document).on('keydown', this._onKeyDown);
|
|
118
|
+
$(window).on('scroll', this._onScroll);
|
|
119
|
+
$(document).on('mousedown', this._onMouseDown);
|
|
120
|
+
$(document).on('mousemove', this._onMouseMove);
|
|
121
|
+
this.bindedHandlers = true;
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
unbindEventHandlers() {
|
|
125
|
+
if (!this.bindedHandlers) {
|
|
126
|
+
return;
|
|
127
|
+
}
|
|
128
|
+
$(document).off('keydown', this._onKeyDown);
|
|
129
|
+
$(window).off('scroll', this._onScroll);
|
|
130
|
+
$(document).off('mousedown', this._onMouseDown);
|
|
131
|
+
$(document).off('mousemove', this._onMouseMove);
|
|
132
|
+
this.bindedHandlers = false;
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
onMarkerActionClick(ev) {
|
|
136
|
+
const color = $(ev.currentTarget).attr('data-color');
|
|
137
|
+
this.markSelection(color);
|
|
138
|
+
this.close();
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
onMarkerMouseDown(ev) {
|
|
142
|
+
ev.stopPropagation();
|
|
143
|
+
ev.preventDefault();
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
onKeyDown() {
|
|
147
|
+
this.close();
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
onScroll() {
|
|
151
|
+
this.close();
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
onMouseMove(ev) {
|
|
155
|
+
this.updateMarkerOpacity(ev.clientX, ev.clientY);
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
onMouseDown() {
|
|
159
|
+
this.close();
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
updateMarkerOpacity(x, y) {
|
|
163
|
+
const markerRect = this.$dom[0].getBoundingClientRect();
|
|
164
|
+
const distance = distanceToRect(x, y, markerRect);
|
|
165
|
+
if (distance > MARKER_MAX_DISTANCE) {
|
|
166
|
+
this.close();
|
|
167
|
+
return;
|
|
168
|
+
}
|
|
169
|
+
this.$dom.css('opacity', 1 - (distance / MARKER_MAX_DISTANCE));
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
destroy() {
|
|
173
|
+
this.close();
|
|
174
|
+
this.$dom.remove();
|
|
175
|
+
markerInstance = null;
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
const MarkerInterface = {
|
|
180
|
+
close() {
|
|
181
|
+
if (!markerInstance) {
|
|
182
|
+
return;
|
|
183
|
+
}
|
|
184
|
+
markerInstance.close();
|
|
185
|
+
},
|
|
186
|
+
showAtPosition($container, x, y) {
|
|
187
|
+
const marker = new Marker();
|
|
188
|
+
marker.showAtPosition($container, x, y);
|
|
189
|
+
},
|
|
190
|
+
};
|
|
191
|
+
|
|
192
|
+
export default MarkerInterface;
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import $ from 'jquery';
|
|
2
|
+
import DOMAttachedObject from 'vj/components/DOMAttachedObject';
|
|
3
|
+
import { delay } from 'vj/utils';
|
|
4
|
+
import Marker from './Marker';
|
|
5
|
+
|
|
6
|
+
export default class MarkerReactive extends DOMAttachedObject {
|
|
7
|
+
static DOMAttachKey = 'vjMarkerReactiveInstance';
|
|
8
|
+
|
|
9
|
+
static initFromDOM($dom) {
|
|
10
|
+
return MarkerReactive.getOrConstruct($dom);
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
static initAll() {
|
|
14
|
+
$('[data-marker-enabled]').get().forEach((dom) => MarkerReactive.initFromDOM($(dom)));
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
constructor($target) {
|
|
18
|
+
super($target);
|
|
19
|
+
this._onMouseUp = this.onMouseUp.bind(this);
|
|
20
|
+
this.bindEventHandlers();
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
bindEventHandlers() {
|
|
24
|
+
this.$dom.on('mouseup', this._onMouseUp);
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
unbindEventHandlers() {
|
|
28
|
+
this.$dom.off('mouseup', this._onMouseUp);
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
async onMouseUp(ev) {
|
|
32
|
+
await delay(1);
|
|
33
|
+
if (!window.getSelection) {
|
|
34
|
+
return;
|
|
35
|
+
}
|
|
36
|
+
const selection = window.getSelection();
|
|
37
|
+
if (!selection || selection.rangeCount === 0) {
|
|
38
|
+
return;
|
|
39
|
+
}
|
|
40
|
+
const range = selection.getRangeAt(0);
|
|
41
|
+
if (range.collapsed) {
|
|
42
|
+
return;
|
|
43
|
+
}
|
|
44
|
+
Marker.showAtPosition(this.$dom, ev.clientX, ev.clientY);
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
detach() {
|
|
48
|
+
if (this.detached) {
|
|
49
|
+
return;
|
|
50
|
+
}
|
|
51
|
+
this.unbindEventHandlers();
|
|
52
|
+
Marker.close();
|
|
53
|
+
super.detach();
|
|
54
|
+
}
|
|
55
|
+
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
[data-marker-enabled]
|
|
2
|
+
outline: 0
|
|
3
|
+
|
|
4
|
+
body > .marker
|
|
5
|
+
position: fixed
|
|
6
|
+
z-index: 100
|
|
7
|
+
display: none
|
|
8
|
+
box-shadow: 0 2px 7px rgba(#000, 0.3)
|
|
9
|
+
background: #FFF
|
|
10
|
+
font-size: rem($font-size-small)
|
|
11
|
+
transition: transform .1s ease-out, opacity .1s ease-out
|
|
12
|
+
transform: scale(0.8)
|
|
13
|
+
transform-origin: 0 100%
|
|
14
|
+
pointer-events: none
|
|
15
|
+
background: #FFF
|
|
16
|
+
padding: 1px
|
|
17
|
+
border: 1px solid #AAA
|
|
18
|
+
|
|
19
|
+
&.open
|
|
20
|
+
transform: none
|
|
21
|
+
pointer-events: auto
|
|
22
|
+
|
|
23
|
+
.marker__toolbar
|
|
24
|
+
padding: 1px
|
|
25
|
+
background: $toolbar-bg
|
|
26
|
+
white-space: nowrap
|
|
27
|
+
font-size: 0
|
|
28
|
+
|
|
29
|
+
.marker__action
|
|
30
|
+
display: inline-block
|
|
31
|
+
text-align: center
|
|
32
|
+
font-size: rem($font-size-icon)
|
|
33
|
+
vertical-align: top
|
|
34
|
+
cursor: pointer
|
|
35
|
+
padding: rem(8px)
|
|
36
|
+
color: $toolbar-fore
|
|
37
|
+
position: relative
|
|
38
|
+
|
|
39
|
+
&:hover
|
|
40
|
+
background: $toolbar-bg-hover
|
|
41
|
+
color: $toolbar-fore-hover
|
|
42
|
+
|
|
43
|
+
.marker__icon
|
|
44
|
+
display: block
|
|
45
|
+
margin: rem(2px)
|
|
46
|
+
width: rem(12px)
|
|
47
|
+
height: rem(12px)
|
|
48
|
+
border-radius: 50%
|
|
49
|
+
|
|
50
|
+
&.icon-yellow
|
|
51
|
+
background: #ffc100
|
|
52
|
+
|
|
53
|
+
&.icon-green
|
|
54
|
+
background: #54d651
|
|
55
|
+
|
|
56
|
+
&.icon-red
|
|
57
|
+
background: #ff3b30
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import $ from 'jquery';
|
|
2
|
+
import { AutoloadPage } from 'vj/misc/Page';
|
|
3
|
+
import { request } from 'vj/utils';
|
|
4
|
+
|
|
5
|
+
export default new AutoloadPage('media', async () => {
|
|
6
|
+
async function parseMedia($dom = $(document.body)) {
|
|
7
|
+
const items = [];
|
|
8
|
+
const resolvers = [];
|
|
9
|
+
const users = $dom.find('div[data-user]');
|
|
10
|
+
const resolve = (ele, item) => {
|
|
11
|
+
items.push(item);
|
|
12
|
+
resolvers.push((html) => html && $(ele).replaceWith($(html)));
|
|
13
|
+
};
|
|
14
|
+
users.get().forEach((ele) => resolve(ele, { type: 'user', id: +$(ele).text() }));
|
|
15
|
+
$dom.find('.typo').addBack('.typo').get().forEach((el) => {
|
|
16
|
+
if (el.className.includes('no-media')) return;
|
|
17
|
+
$(el).find('a[href]').get().forEach((ele) => {
|
|
18
|
+
if ($(ele).parent().hasClass('user-profile-link')) return;
|
|
19
|
+
let target = $(ele).attr('href');
|
|
20
|
+
let { domainId } = UiContext;
|
|
21
|
+
if (target.startsWith(UiContext.url_prefix)) {
|
|
22
|
+
target.replace(UiContext.url_prefix, '');
|
|
23
|
+
if (!target.startsWith('/')) target = `/${target}`;
|
|
24
|
+
}
|
|
25
|
+
if (!target.startsWith('/') || target.startsWith('//')) return;
|
|
26
|
+
if (target.startsWith('/d/')) {
|
|
27
|
+
const [, , domain, ...extra] = target.split('/');
|
|
28
|
+
domainId = domain;
|
|
29
|
+
target = `/${extra.join('/')}`;
|
|
30
|
+
}
|
|
31
|
+
const [, category, data, extra] = target.split('/');
|
|
32
|
+
if (!data) return;
|
|
33
|
+
if (category === 'user' && Number.isInteger(+data) && !extra) resolve(ele, { type: 'user', id: +data });
|
|
34
|
+
if (category === 'p' && !extra) resolve(ele, { type: 'problem', id: data, domainId });
|
|
35
|
+
if (category === 'contest' && !extra) resolve(ele, { type: 'contest', id: data, domainId });
|
|
36
|
+
if (category === 'homework' && !extra) resolve(ele, { type: 'homework', id: data, domainId });
|
|
37
|
+
});
|
|
38
|
+
});
|
|
39
|
+
if (!items.length) return;
|
|
40
|
+
const res = await request.post(`/d/${UiContext.domainId}/media`, { items });
|
|
41
|
+
for (let i = 0; i < res.length; i++) resolvers[i](res[i]);
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
await parseMedia();
|
|
45
|
+
$(document).on('vjContentNew', (e) => parseMedia($(e.target)));
|
|
46
|
+
});
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import $ from 'jquery';
|
|
2
|
+
import { AutoloadPage } from 'vj/misc/Page';
|
|
3
|
+
import { tpl } from 'vj/utils';
|
|
4
|
+
|
|
5
|
+
const menuHeadingPage = new AutoloadPage('menuHeadingPage', null, () => {
|
|
6
|
+
$('[data-heading-extract-to]').get().forEach((container) => {
|
|
7
|
+
const $container = $(container);
|
|
8
|
+
const $target = $('body').find($container.attr('data-heading-extract-to'));
|
|
9
|
+
if ($target.length === 0) return;
|
|
10
|
+
let $menu = $target.children('.menu');
|
|
11
|
+
if ($menu.length === 0) {
|
|
12
|
+
$menu = $(tpl`<ul class="menu collapsed"></ul>`).appendTo($target);
|
|
13
|
+
$target.children('.menu__link').addClass('expandable');
|
|
14
|
+
}
|
|
15
|
+
$container.find('[data-heading]').get().forEach((heading) => {
|
|
16
|
+
const $heading = $(heading);
|
|
17
|
+
$(tpl`
|
|
18
|
+
<li class="menu__item">
|
|
19
|
+
<a class="menu__link" href="#${$heading.attr('id') || ''}">
|
|
20
|
+
${$heading.text()}
|
|
21
|
+
</a>
|
|
22
|
+
</li>
|
|
23
|
+
`).appendTo($menu);
|
|
24
|
+
});
|
|
25
|
+
});
|
|
26
|
+
});
|
|
27
|
+
|
|
28
|
+
export default menuHeadingPage;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import $ from 'jquery';
|
|
2
|
+
import { AutoloadPage } from 'vj/misc/Page';
|
|
3
|
+
import { delay, slideDown } from 'vj/utils';
|
|
4
|
+
|
|
5
|
+
function expandMenu($menu) {
|
|
6
|
+
slideDown($menu, 500, { opacity: 0 }, { opacity: 1 });
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
async function expandAllMenus() {
|
|
10
|
+
await delay(200);
|
|
11
|
+
$('.menu.collapsed').get().forEach((menu) => expandMenu($(menu)));
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
const menuPage = new AutoloadPage('menuPage', () => {
|
|
15
|
+
expandAllMenus();
|
|
16
|
+
});
|
|
17
|
+
|
|
18
|
+
export default menuPage;
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
.menu
|
|
2
|
+
padding: rem(5px 0)
|
|
3
|
+
font-size: rem($font-size-secondary)
|
|
4
|
+
|
|
5
|
+
.icon
|
|
6
|
+
font-size: rem($font-size-icon)
|
|
7
|
+
display: inline-block
|
|
8
|
+
margin-right: rem(5px)
|
|
9
|
+
line-height: rem(18px)
|
|
10
|
+
vertical-align: top
|
|
11
|
+
|
|
12
|
+
.hasjs &.collapsed
|
|
13
|
+
display: none
|
|
14
|
+
|
|
15
|
+
.menu__item .menu
|
|
16
|
+
padding: 0
|
|
17
|
+
|
|
18
|
+
.menu__link
|
|
19
|
+
outline: 0
|
|
20
|
+
text-align: left
|
|
21
|
+
display: block
|
|
22
|
+
width: 100%
|
|
23
|
+
padding: rem(12px $section-gap-h)
|
|
24
|
+
line-height: rem(18px)
|
|
25
|
+
color: $text-1-color
|
|
26
|
+
border-left: 3px solid transparent
|
|
27
|
+
position: relative
|
|
28
|
+
|
|
29
|
+
&.highlight
|
|
30
|
+
background: mix($highlight-color, #FFF, 10%)
|
|
31
|
+
|
|
32
|
+
&.expandable:after
|
|
33
|
+
font-family: $icon-font-name
|
|
34
|
+
font-size: rem($font-size-icon)
|
|
35
|
+
content: $icon-expand_more
|
|
36
|
+
position: absolute
|
|
37
|
+
right: $section-gap-h
|
|
38
|
+
top: 50%
|
|
39
|
+
line-height: 1
|
|
40
|
+
margin-top: rem($font-size-icon / -2)
|
|
41
|
+
transition: transform .2s ease-out-cubic
|
|
42
|
+
opacity: 0.85
|
|
43
|
+
|
|
44
|
+
a.menu__link, button.menu__link
|
|
45
|
+
&.half
|
|
46
|
+
padding-right: 0
|
|
47
|
+
width: 50%
|
|
48
|
+
&.disabled
|
|
49
|
+
cursor: default
|
|
50
|
+
opacity: 0.5
|
|
51
|
+
&:hover
|
|
52
|
+
text-decoration: none
|
|
53
|
+
&:not(.disabled):hover
|
|
54
|
+
color: $text-1-color
|
|
55
|
+
background: $menu-item-bg-color-hover
|
|
56
|
+
border-color: darken($primary-color, 10%)
|
|
57
|
+
&.active, &.active:hover
|
|
58
|
+
border-color: darken($secondary-color, 30%)
|
|
59
|
+
background: $secondary-color
|
|
60
|
+
color: #FFF
|
|
61
|
+
|
|
62
|
+
.menu__item .menu .menu__link
|
|
63
|
+
padding-left: rem($section-gap-h + 10px)
|
|
64
|
+
|
|
65
|
+
.menu__seperator
|
|
66
|
+
height: 1px
|
|
67
|
+
border-top: 1px solid #EEE
|
|
68
|
+
margin: rem(5px 0)
|