@oliasoft-open-source/react-ui-library 1.0.0
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/.eslintignore +2 -0
- package/.eslintrc.js +125 -0
- package/.gitlab-ci.yml +45 -0
- package/.husky/pre-commit +4 -0
- package/.prettierignore +3 -0
- package/.prettierrc +4 -0
- package/.storybook/main.js +36 -0
- package/.storybook/preview.js +40 -0
- package/.storybook/storybook.less +8 -0
- package/LICENSE +21 -0
- package/README.md +5 -0
- package/babel.config.js +31 -0
- package/index.js +76 -0
- package/jest.config.js +9 -0
- package/package.json +136 -0
- package/src/components/accordion/accordion.jsx +132 -0
- package/src/components/accordion/accordion.module.less +66 -0
- package/src/components/accordion/accordion.stories.jsx +171 -0
- package/src/components/accordion/chevron/chevron.jsx +12 -0
- package/src/components/accordion/chevron/chevron.module.less +12 -0
- package/src/components/accordion/helpers/accordion-with-default-toggle.jsx +106 -0
- package/src/components/accordion/helpers/accordion-with-default-toggle.module.less +24 -0
- package/src/components/actions/actions.jsx +129 -0
- package/src/components/actions/actions.module.less +44 -0
- package/src/components/actions/actions.shape.js +32 -0
- package/src/components/actions/actions.stories.jsx +79 -0
- package/src/components/badge/badge.jsx +58 -0
- package/src/components/badge/badge.module.less +55 -0
- package/src/components/badge/badge.stories.jsx +31 -0
- package/src/components/breadcrumb/breadcrumb.jsx +49 -0
- package/src/components/breadcrumb/breadcrumb.module.less +39 -0
- package/src/components/breadcrumb/breadcrumb.stories.jsx +45 -0
- package/src/components/breadcrumb/link.jsx +31 -0
- package/src/components/button/button.jsx +156 -0
- package/src/components/button/button.module.less +300 -0
- package/src/components/button/button.stories.jsx +74 -0
- package/src/components/button-group/button-group.jsx +140 -0
- package/src/components/button-group/button-group.module.less +24 -0
- package/src/components/button-group/button-group.stories-data.jsx +67 -0
- package/src/components/button-group/button-group.stories.jsx +63 -0
- package/src/components/buttons-and-links.stories.mdx +55 -0
- package/src/components/card/card.jsx +51 -0
- package/src/components/card/card.module.less +48 -0
- package/src/components/card/card.stories.jsx +39 -0
- package/src/components/check-box/check-box.jsx +92 -0
- package/src/components/check-box/check-box.module.less +101 -0
- package/src/components/check-box/check-box.stories.jsx +27 -0
- package/src/components/color/color.stories-data.jsx +71 -0
- package/src/components/color/color.stories.mdx +37 -0
- package/src/components/dialog/dialog.jsx +64 -0
- package/src/components/dialog/dialog.module.less +76 -0
- package/src/components/divider/divider.jsx +40 -0
- package/src/components/divider/divider.module.less +28 -0
- package/src/components/divider/divider.stories.jsx +50 -0
- package/src/components/drawer/drawer-tabs.jsx +43 -0
- package/src/components/drawer/drawer.jsx +150 -0
- package/src/components/drawer/drawer.module.less +167 -0
- package/src/components/drawer/drawer.stories.jsx +156 -0
- package/src/components/empty/empty.jsx +52 -0
- package/src/components/empty/empty.module.less +17 -0
- package/src/components/empty/empty.stories.jsx +26 -0
- package/src/components/file-input/file-input.jsx +101 -0
- package/src/components/file-input/file-input.module.less +3 -0
- package/src/components/file-input/file-input.stories.jsx +109 -0
- package/src/components/form/field.jsx +96 -0
- package/src/components/form/field.stories.jsx +101 -0
- package/src/components/form/form.module.less +30 -0
- package/src/components/form/form.stories.jsx +191 -0
- package/src/components/heading/heading.jsx +105 -0
- package/src/components/heading/heading.module.less +59 -0
- package/src/components/heading/heading.stories.jsx +60 -0
- package/src/components/icon/deprecated-icon.jsx +97 -0
- package/src/components/icon/icon.jsx +71 -0
- package/src/components/icon/icon.module.less +33 -0
- package/src/components/icon/icon.stories.jsx +37 -0
- package/src/components/icon/icons.example.module.less +4 -0
- package/src/components/input/input.jsx +167 -0
- package/src/components/input/input.module.less +94 -0
- package/src/components/input/input.stories.jsx +28 -0
- package/src/components/input-group/input-group-addon/input-group-addon.jsx +36 -0
- package/src/components/input-group/input-group-addon/input-group-addon.module.less +31 -0
- package/src/components/input-group/input-group.jsx +51 -0
- package/src/components/input-group/input-group.module.less +10 -0
- package/src/components/input-group/input-group.stories.jsx +77 -0
- package/src/components/input-validation.stories.mdx +61 -0
- package/src/components/inputs.stories.mdx +201 -0
- package/src/components/label/label.jsx +115 -0
- package/src/components/label/label.module.less +43 -0
- package/src/components/label/label.stories.jsx +60 -0
- package/src/components/layout/column/column.jsx +85 -0
- package/src/components/layout/column/styles.js +45 -0
- package/src/components/layout/column.stories.jsx +60 -0
- package/src/components/layout/examples/afe.stories.jsx +180 -0
- package/src/components/layout/examples/blowout.stories.jsx +68 -0
- package/src/components/layout/examples/casing-loads.stories.jsx +297 -0
- package/src/components/layout/examples/formation.stories.jsx +110 -0
- package/src/components/layout/examples/projects.stories.jsx +108 -0
- package/src/components/layout/examples/reservoirs.stories.jsx +211 -0
- package/src/components/layout/examples/site.stories.jsx +263 -0
- package/src/components/layout/flex/flex.jsx +48 -0
- package/src/components/layout/flex/flex.stories.jsx +54 -0
- package/src/components/layout/form-row/form-row.jsx +15 -0
- package/src/components/layout/form-row/form-row.module.less +11 -0
- package/src/components/layout/grid/grid.jsx +62 -0
- package/src/components/layout/grid/grid.stories.jsx +65 -0
- package/src/components/layout/page/page.jsx +42 -0
- package/src/components/layout/page/page.module.less +27 -0
- package/src/components/layout/page.stories.jsx +93 -0
- package/src/components/layout/placeholder.jsx +2 -0
- package/src/components/layout/print-header/print-header.jsx +22 -0
- package/src/components/layout/print-header/print-header.module.less +9 -0
- package/src/components/layout/row/row.jsx +75 -0
- package/src/components/layout/row/row.module.less +7 -0
- package/src/components/layout/spacer/spacer.jsx +26 -0
- package/src/components/layout/spacer/spacer.stories.jsx +50 -0
- package/src/components/layout-forms.stories.mdx +104 -0
- package/src/components/layout-general.stories.mdx +215 -0
- package/src/components/list/list-row/item-content.jsx +15 -0
- package/src/components/list/list-row/label.jsx +11 -0
- package/src/components/list/list-row/list-heading.jsx +52 -0
- package/src/components/list/list-row/list-row.jsx +128 -0
- package/src/components/list/list-row/list-subheading.jsx +72 -0
- package/src/components/list/list-row/meta-content.jsx +24 -0
- package/src/components/list/list-row/meta-count.jsx +10 -0
- package/src/components/list/list-row/name.jsx +45 -0
- package/src/components/list/list.jsx +276 -0
- package/src/components/list/list.module.less +256 -0
- package/src/components/list/list.stories-data.jsx +287 -0
- package/src/components/list/list.stories.jsx +458 -0
- package/src/components/list/toggle-narrow.jsx +13 -0
- package/src/components/loader/loader.jsx +63 -0
- package/src/components/loader/loader.module.less +63 -0
- package/src/components/loader/loader.stories.jsx +155 -0
- package/src/components/menu/index.js +7 -0
- package/src/components/menu/layer/divider.jsx +4 -0
- package/src/components/menu/layer/heading.jsx +15 -0
- package/src/components/menu/layer/layer.jsx +82 -0
- package/src/components/menu/layer/option.jsx +77 -0
- package/src/components/menu/layer/path.js +44 -0
- package/src/components/menu/layer/placementOptions.js +6 -0
- package/src/components/menu/layer/section.jsx +66 -0
- package/src/components/menu/menu.jsx +359 -0
- package/src/components/menu/menu.module.less +241 -0
- package/src/components/menu/menu.stories-data.jsx +168 -0
- package/src/components/menu/menu.stories.jsx +126 -0
- package/src/components/menu/menu.test.js +58 -0
- package/src/components/menu/trigger/button.jsx +50 -0
- package/src/components/menu/trigger/component.jsx +14 -0
- package/src/components/menu/trigger/text.jsx +25 -0
- package/src/components/menu/trigger/trigger.jsx +86 -0
- package/src/components/message/dismiss.jsx +26 -0
- package/src/components/message/message.jsx +137 -0
- package/src/components/message/message.module.less +114 -0
- package/src/components/message/message.stories.jsx +84 -0
- package/src/components/modal/modal.jsx +50 -0
- package/src/components/modal/modal.module.less +35 -0
- package/src/components/modal/modal.stories.jsx +159 -0
- package/src/components/option-dropdown/heading.jsx +6 -0
- package/src/components/option-dropdown/layer.jsx +81 -0
- package/src/components/option-dropdown/option-dropdown.jsx +53 -0
- package/src/components/option-dropdown/option-dropdown.module.less +50 -0
- package/src/components/option-dropdown/option-dropdown.stories.jsx +35 -0
- package/src/components/option-dropdown/option.jsx +13 -0
- package/src/components/pagination/pagination.jsx +139 -0
- package/src/components/pagination/pagination.module.less +11 -0
- package/src/components/pagination/pagination.stories.jsx +78 -0
- package/src/components/pagination/pagination.test.js +92 -0
- package/src/components/pagination/pagination.viewdata.js +66 -0
- package/src/components/pop-confirm/content.jsx +25 -0
- package/src/components/pop-confirm/pop-confirm.jsx +61 -0
- package/src/components/pop-confirm/pop-confirm.module.less +18 -0
- package/src/components/pop-confirm/pop-confirm.stories.jsx +53 -0
- package/src/components/popover/popover.jsx +112 -0
- package/src/components/popover/popover.module.less +22 -0
- package/src/components/popover/popover.stories.jsx +59 -0
- package/src/components/portal/portal.jsx +16 -0
- package/src/components/portal/portal.stories.jsx +69 -0
- package/src/components/progress-bar/progress-bar.jsx +64 -0
- package/src/components/progress-bar/progress-bar.module.less +64 -0
- package/src/components/progress-bar/progress-bar.stories.jsx +23 -0
- package/src/components/radio-button/radio-button.jsx +139 -0
- package/src/components/radio-button/radio-button.module.less +135 -0
- package/src/components/radio-button/radio-button.stories.jsx +37 -0
- package/src/components/radio-button/radio-input.jsx +52 -0
- package/src/components/select/custom-select/custom-select.jsx +440 -0
- package/src/components/select/custom-select/custom-select.module.less +123 -0
- package/src/components/select/custom-select/custom-select.reducer.js +157 -0
- package/src/components/select/custom-select/layer/heading.jsx +13 -0
- package/src/components/select/custom-select/layer/layer.jsx +73 -0
- package/src/components/select/custom-select/layer/option.jsx +54 -0
- package/src/components/select/custom-select/layer/placementOptions.js +7 -0
- package/src/components/select/custom-select/layer/section.jsx +35 -0
- package/src/components/select/custom-select/trigger/input.jsx +100 -0
- package/src/components/select/custom-select/trigger/trigger.jsx +155 -0
- package/src/components/select/custom-select/trigger/trigger.module.less +289 -0
- package/src/components/select/native-select/native-select.jsx +198 -0
- package/src/components/select/native-select/native-select.module.less +107 -0
- package/src/components/select/select.input.js +146 -0
- package/src/components/select/select.jsx +207 -0
- package/src/components/select/select.stories-data.jsx +92 -0
- package/src/components/select/select.stories.jsx +135 -0
- package/src/components/select/select.test.js +519 -0
- package/src/components/side-bar/container.module.less +29 -0
- package/src/components/side-bar/link.jsx +83 -0
- package/src/components/side-bar/sections.jsx +23 -0
- package/src/components/side-bar/side-bar.jsx +102 -0
- package/src/components/side-bar/side-bar.module.less +137 -0
- package/src/components/side-bar/side-bar.stories.jsx +101 -0
- package/src/components/slider/rc-slider.less +47 -0
- package/src/components/slider/slider-tooltip.jsx +20 -0
- package/src/components/slider/slider.jsx +233 -0
- package/src/components/slider/slider.module.less +40 -0
- package/src/components/slider/slider.stories.jsx +110 -0
- package/src/components/spinner/spinner.jsx +37 -0
- package/src/components/spinner/spinner.module.less +115 -0
- package/src/components/spinner/spinner.stories.jsx +24 -0
- package/src/components/table/cell/cell.jsx +614 -0
- package/src/components/table/cell/cell.module.less +152 -0
- package/src/components/table/footer/footer.jsx +66 -0
- package/src/components/table/footer/footer.module.less +14 -0
- package/src/components/table/helper.js +64 -0
- package/src/components/table/helper.test.js +166 -0
- package/src/components/table/icon/icon.module.less +31 -0
- package/src/components/table/row/expanded-content-row.jsx +16 -0
- package/src/components/table/row/row.jsx +253 -0
- package/src/components/table/row/row.module.less +62 -0
- package/src/components/table/table-scroll-wrapper.jsx +48 -0
- package/src/components/table/table.jsx +232 -0
- package/src/components/table/table.module.less +145 -0
- package/src/components/table/table.stories-data.jsx +752 -0
- package/src/components/table/table.stories.jsx +814 -0
- package/src/components/table/table.test.js +30 -0
- package/src/components/table/table.variables.less +19 -0
- package/src/components/table/table.viewdata.js +26 -0
- package/src/components/table/title/title.jsx +30 -0
- package/src/components/table/title/title.module.less +9 -0
- package/src/components/tabs/content.jsx +14 -0
- package/src/components/tabs/label.jsx +50 -0
- package/src/components/tabs/tabs.jsx +191 -0
- package/src/components/tabs/tabs.module.less +73 -0
- package/src/components/tabs/tabs.stories.jsx +110 -0
- package/src/components/text/text.jsx +64 -0
- package/src/components/text/text.module.less +45 -0
- package/src/components/text/text.stories.jsx +31 -0
- package/src/components/text-link/text-link.jsx +23 -0
- package/src/components/text-link/text-link.stories.jsx +20 -0
- package/src/components/textarea/textarea.jsx +126 -0
- package/src/components/textarea/textarea.module.less +55 -0
- package/src/components/textarea/textarea.stories.jsx +26 -0
- package/src/components/toaster/toaster.jsx +39 -0
- package/src/components/toaster/toaster.less +17 -0
- package/src/components/toaster/toaster.stories.jsx +116 -0
- package/src/components/toggle/toggle.jsx +65 -0
- package/src/components/toggle/toggle.module.less +139 -0
- package/src/components/toggle/toggle.stories.jsx +26 -0
- package/src/components/tooltip/tooltip-layer.jsx +72 -0
- package/src/components/tooltip/tooltip.jsx +108 -0
- package/src/components/tooltip/tooltip.module.less +28 -0
- package/src/components/tooltip/tooltip.stories.jsx +71 -0
- package/src/components/top-bar/element/element.jsx +72 -0
- package/src/components/top-bar/element/link.jsx +29 -0
- package/src/components/top-bar/title.jsx +24 -0
- package/src/components/top-bar/top-bar.jsx +79 -0
- package/src/components/top-bar/top-bar.module.less +191 -0
- package/src/components/top-bar/top-bar.stories.jsx +137 -0
- package/src/components/top-bar/warning.jsx +6 -0
- package/src/components/tree/tree-item.jsx +79 -0
- package/src/components/tree/tree-placeholder.jsx +6 -0
- package/src/components/tree/tree.jsx +129 -0
- package/src/components/tree/tree.module.less +33 -0
- package/src/components/tree/tree.stories-data.jsx +89 -0
- package/src/components/tree/tree.stories.jsx +106 -0
- package/src/docs/components/page/page.jsx +16 -0
- package/src/docs/config/config.js +1 -0
- package/src/docs/html/favicon.png +0 -0
- package/src/docs/html/index.html +11 -0
- package/src/docs/navigation/footer/footer.jsx +48 -0
- package/src/docs/navigation/header/header.jsx +39 -0
- package/src/docs/navigation/header/header.module.less +32 -0
- package/src/docs/navigation/routes/routes.jsx +16 -0
- package/src/docs/start.jsx +12 -0
- package/src/docs/views/main/main.jsx +209 -0
- package/src/docs/views/main/main.module.less +14 -0
- package/src/docs/views/not-found/not-found.jsx +5 -0
- package/src/helpers/disabled-context.js +8 -0
- package/src/helpers/styles.js +68 -0
- package/src/helpers/text.js +6 -0
- package/src/helpers/types.js +5 -0
- package/src/hooks/index.js +3 -0
- package/src/hooks/use-focus.js +11 -0
- package/src/hooks/use-keyboard-event.js +16 -0
- package/src/hooks/use-window-width.js +20 -0
- package/src/images/icons/icon-drop.png +0 -0
- package/src/images/icons/icon-share.png +0 -0
- package/src/images/icons/icons8-junction.svg +4 -0
- package/src/images/logo.png +0 -0
- package/src/images/logo.svg +13 -0
- package/src/images/oliasoft-logo.svg +1 -0
- package/src/style/colors.less +26 -0
- package/src/style/external.less +10 -0
- package/src/style/fonts/lato/Lato-Bold.woff2 +0 -0
- package/src/style/fonts/lato/Lato-BoldItalic.woff2 +0 -0
- package/src/style/fonts/lato/Lato-Italic.woff2 +0 -0
- package/src/style/fonts/lato/Lato-Regular.woff2 +0 -0
- package/src/style/fonts.less +27 -0
- package/src/style/global.less +51 -0
- package/src/style/mixins.less +67 -0
- package/src/style/reset/reset.less +34 -0
- package/src/style/shared.less +25 -0
- package/src/style/theme.dark.less +37 -0
- package/src/style/theme.default.less +74 -0
- package/src/style/variables.less +49 -0
- package/webpack/webpack.common.js +39 -0
- package/webpack/webpack.common.rules.js +102 -0
- package/webpack/webpack.dev.js +22 -0
- package/webpack/webpack.prod.js +23 -0
- package/webpack/webpack.resolve.js +22 -0
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Link } from 'react-router-dom';
|
|
3
|
+
import { ImMobile } from 'react-icons/im';
|
|
4
|
+
import { SiStorybook } from 'react-icons/si';
|
|
5
|
+
import { TopBar } from '../../../../index';
|
|
6
|
+
import { baseUrl } from '../../config/config';
|
|
7
|
+
import styles from './header.module.less';
|
|
8
|
+
|
|
9
|
+
export const Header = () => {
|
|
10
|
+
const storybookUrl = `${baseUrl}storybook/`;
|
|
11
|
+
return (
|
|
12
|
+
<TopBar
|
|
13
|
+
content={[
|
|
14
|
+
{
|
|
15
|
+
type: 'Component',
|
|
16
|
+
component: (
|
|
17
|
+
<span className={styles.link}>
|
|
18
|
+
<Link to="/">
|
|
19
|
+
<ImMobile color="var(--color-text-primary)" size={40} />
|
|
20
|
+
<span>React UI Library</span>
|
|
21
|
+
</Link>
|
|
22
|
+
</span>
|
|
23
|
+
),
|
|
24
|
+
},
|
|
25
|
+
]}
|
|
26
|
+
contentRight={[
|
|
27
|
+
{
|
|
28
|
+
type: 'Button',
|
|
29
|
+
label: 'Storybook',
|
|
30
|
+
icon: <SiStorybook />,
|
|
31
|
+
onClick: () => {
|
|
32
|
+
const win = window.open(storybookUrl, '_blank');
|
|
33
|
+
win.focus();
|
|
34
|
+
},
|
|
35
|
+
},
|
|
36
|
+
]}
|
|
37
|
+
/>
|
|
38
|
+
);
|
|
39
|
+
};
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
.link {
|
|
2
|
+
a {
|
|
3
|
+
display: flex;
|
|
4
|
+
justify-content: center;
|
|
5
|
+
align-items: center;
|
|
6
|
+
|
|
7
|
+
text-transform: uppercase;
|
|
8
|
+
letter-spacing: 0.1em;
|
|
9
|
+
white-space: nowrap;
|
|
10
|
+
|
|
11
|
+
img,
|
|
12
|
+
svg {
|
|
13
|
+
max-height: 30px;
|
|
14
|
+
max-width: 200px;
|
|
15
|
+
height: auto;
|
|
16
|
+
width: auto;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
span {
|
|
20
|
+
margin-left: 10px;
|
|
21
|
+
white-space: nowrap;
|
|
22
|
+
|
|
23
|
+
@media (max-width: 700px) {
|
|
24
|
+
display: none;
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
&:hover {
|
|
29
|
+
text-decoration: none;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { HashRouter as Router, Route } from 'react-router-dom';
|
|
3
|
+
|
|
4
|
+
import { Main } from '../../views/main/main';
|
|
5
|
+
|
|
6
|
+
export const Routes = () => {
|
|
7
|
+
return (
|
|
8
|
+
<>
|
|
9
|
+
<Router>
|
|
10
|
+
<Route path="/" exact>
|
|
11
|
+
<Main />
|
|
12
|
+
</Route>
|
|
13
|
+
</Router>
|
|
14
|
+
</>
|
|
15
|
+
);
|
|
16
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import ReactDOM from 'react-dom';
|
|
3
|
+
|
|
4
|
+
import { Routes } from './navigation/routes/routes';
|
|
5
|
+
|
|
6
|
+
import '../style/global.less';
|
|
7
|
+
|
|
8
|
+
const Root = () => {
|
|
9
|
+
return <Routes />;
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
ReactDOM.render(<Root />, document.getElementById('content'));
|
|
@@ -0,0 +1,209 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import {
|
|
3
|
+
FaCode,
|
|
4
|
+
FaCogs,
|
|
5
|
+
FaWpforms,
|
|
6
|
+
FaExternalLinkAlt,
|
|
7
|
+
FaRegWindowMaximize,
|
|
8
|
+
FaListUl,
|
|
9
|
+
FaPaintBrush,
|
|
10
|
+
} from 'react-icons/fa';
|
|
11
|
+
import { BsFillGridFill } from 'react-icons/bs';
|
|
12
|
+
import { MdTabletMac } from 'react-icons/md';
|
|
13
|
+
import { RiPagesFill, RiArchiveDrawerFill, RiChat2Line } from 'react-icons/ri';
|
|
14
|
+
import { SiStorybook } from 'react-icons/si';
|
|
15
|
+
import { TiInputChecked } from 'react-icons/ti';
|
|
16
|
+
import { AiOutlineUngroup } from 'react-icons/ai';
|
|
17
|
+
import { ImTable, ImSpinner8, ImBell } from 'react-icons/im';
|
|
18
|
+
import {
|
|
19
|
+
Card,
|
|
20
|
+
Spacer,
|
|
21
|
+
Heading,
|
|
22
|
+
TextLink,
|
|
23
|
+
Text,
|
|
24
|
+
Flex,
|
|
25
|
+
Grid,
|
|
26
|
+
Button,
|
|
27
|
+
} from '../../../../index';
|
|
28
|
+
import { Page } from '../../components/page/page';
|
|
29
|
+
import { baseUrl } from '../../config/config';
|
|
30
|
+
import styles from './main.module.less';
|
|
31
|
+
|
|
32
|
+
const description = [
|
|
33
|
+
{
|
|
34
|
+
title: 'Comprehensive',
|
|
35
|
+
icon: <BsFillGridFill size={36} />,
|
|
36
|
+
text: (
|
|
37
|
+
<>
|
|
38
|
+
A <strong>comprehensive</strong> set of layout, navigation and control
|
|
39
|
+
components for building modern web apps.
|
|
40
|
+
</>
|
|
41
|
+
),
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
title: 'Configurable',
|
|
45
|
+
icon: <FaCogs size={36} />,
|
|
46
|
+
text: (
|
|
47
|
+
<>
|
|
48
|
+
<strong>Flexible</strong>, configurable components with detailed usage
|
|
49
|
+
examples via Storybook.
|
|
50
|
+
</>
|
|
51
|
+
),
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
title: 'Responsive',
|
|
55
|
+
icon: <MdTabletMac size={36} />,
|
|
56
|
+
text: (
|
|
57
|
+
<>
|
|
58
|
+
Easily build <strong>responsive</strong> layouts that work well on a
|
|
59
|
+
variety of devices.
|
|
60
|
+
</>
|
|
61
|
+
),
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
title: 'Open-source',
|
|
65
|
+
icon: <FaCode size={36} />,
|
|
66
|
+
text: (
|
|
67
|
+
<>
|
|
68
|
+
Contribute and fork freely under a permissive,{' '}
|
|
69
|
+
<strong>open-source</strong>{' '}
|
|
70
|
+
<TextLink href="https://gitlab.com/oliasoft-open-source/react-ui-library/-/blob/master/LICENSE">
|
|
71
|
+
MIT License.
|
|
72
|
+
</TextLink>
|
|
73
|
+
</>
|
|
74
|
+
),
|
|
75
|
+
},
|
|
76
|
+
];
|
|
77
|
+
|
|
78
|
+
const features = [
|
|
79
|
+
{
|
|
80
|
+
title: 'Page Layouts',
|
|
81
|
+
icon: <RiPagesFill size={36} />,
|
|
82
|
+
text: 'Support for responsive layouts with Page, Row, Column, Card, and Accordion components.',
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
title: 'Drawers',
|
|
86
|
+
icon: <RiArchiveDrawerFill size={36} />,
|
|
87
|
+
text: 'Easily support expandable drawers.',
|
|
88
|
+
},
|
|
89
|
+
{
|
|
90
|
+
title: 'Navigation',
|
|
91
|
+
icon: <FaExternalLinkAlt size={36} />,
|
|
92
|
+
text: 'Flexible TopBar, SideBar, Tabs, Breadcrumbs, Pagination and other navigation components.',
|
|
93
|
+
},
|
|
94
|
+
{
|
|
95
|
+
title: 'Inputs',
|
|
96
|
+
icon: <TiInputChecked size={36} />,
|
|
97
|
+
text: 'Comprehensive inputs including Selects, Checkboxes, Toggles, RadioButtons, Buttons, and Sliders.',
|
|
98
|
+
},
|
|
99
|
+
{
|
|
100
|
+
title: 'Input Groups',
|
|
101
|
+
icon: <AiOutlineUngroup size={36} />,
|
|
102
|
+
text: 'Combine groups of inputs flexible ways, including text-label addons.',
|
|
103
|
+
},
|
|
104
|
+
{
|
|
105
|
+
title: 'Form Layouts',
|
|
106
|
+
icon: <FaWpforms size={36} />,
|
|
107
|
+
text: 'Convenient stacked and row form layouts, with all inputs supported.',
|
|
108
|
+
},
|
|
109
|
+
{
|
|
110
|
+
title: 'Notifications',
|
|
111
|
+
icon: <ImBell size={36} />,
|
|
112
|
+
text: 'Consistently-styled Messages and toast Messages.',
|
|
113
|
+
},
|
|
114
|
+
{
|
|
115
|
+
title: 'Tables',
|
|
116
|
+
icon: <ImTable size={36} />,
|
|
117
|
+
text: 'A configurable table component with support for many input and custom cells.',
|
|
118
|
+
},
|
|
119
|
+
{
|
|
120
|
+
title: 'Lists',
|
|
121
|
+
icon: <FaListUl size={36} />,
|
|
122
|
+
text: 'A configurable list component.',
|
|
123
|
+
},
|
|
124
|
+
{
|
|
125
|
+
title: 'Progress',
|
|
126
|
+
icon: <ImSpinner8 size={36} />,
|
|
127
|
+
text: 'Flexible spinners and loaders.',
|
|
128
|
+
},
|
|
129
|
+
{
|
|
130
|
+
title: 'Modals',
|
|
131
|
+
icon: <FaRegWindowMaximize size={36} />,
|
|
132
|
+
text: 'Simple, flexible Modals and Dialogs.',
|
|
133
|
+
},
|
|
134
|
+
{
|
|
135
|
+
title: 'Modern Popover Engine',
|
|
136
|
+
icon: <RiChat2Line size={36} />,
|
|
137
|
+
text: (
|
|
138
|
+
<>
|
|
139
|
+
Uses a React-friendly positioning engine (
|
|
140
|
+
<a href="https://www.react-laag.com/">React-Laag</a>) for popovers,
|
|
141
|
+
tooltips menus, and custom selects.
|
|
142
|
+
</>
|
|
143
|
+
),
|
|
144
|
+
},
|
|
145
|
+
{
|
|
146
|
+
title: 'Flexible styling',
|
|
147
|
+
icon: <FaPaintBrush size={36} />,
|
|
148
|
+
text: (
|
|
149
|
+
<>
|
|
150
|
+
Supports the two most popular React styling approaches:{' '}
|
|
151
|
+
<a href="https://github.com/css-modules/css-modules/">CSS Modules</a>{' '}
|
|
152
|
+
and <a href="https://styled-components.com/">styled-components</a>.
|
|
153
|
+
</>
|
|
154
|
+
),
|
|
155
|
+
},
|
|
156
|
+
];
|
|
157
|
+
|
|
158
|
+
export const Main = () => {
|
|
159
|
+
const storybookUrl = `${baseUrl}storybook/`;
|
|
160
|
+
return (
|
|
161
|
+
<Page>
|
|
162
|
+
<div className={styles.container}>
|
|
163
|
+
<Spacer height="100px" />
|
|
164
|
+
<Flex direction="column">
|
|
165
|
+
<h1 className={styles.headline}>
|
|
166
|
+
User Interface Components for React Applications
|
|
167
|
+
</h1>
|
|
168
|
+
{description.map((item, index) => (
|
|
169
|
+
<p className={styles.lead} key={index}>
|
|
170
|
+
<Text muted>{item.text}</Text>
|
|
171
|
+
</p>
|
|
172
|
+
))}
|
|
173
|
+
</Flex>
|
|
174
|
+
|
|
175
|
+
<Spacer height="30px" />
|
|
176
|
+
|
|
177
|
+
<Button
|
|
178
|
+
label="Storybook"
|
|
179
|
+
colored
|
|
180
|
+
icon={<SiStorybook />}
|
|
181
|
+
onClick={() => {
|
|
182
|
+
const win = window.open(storybookUrl, '_blank');
|
|
183
|
+
win.focus();
|
|
184
|
+
}}
|
|
185
|
+
/>
|
|
186
|
+
|
|
187
|
+
<Spacer height="100px" />
|
|
188
|
+
|
|
189
|
+
<Grid
|
|
190
|
+
columns="1fr 1fr 1fr 1fr"
|
|
191
|
+
columnsTablet="1fr 1fr"
|
|
192
|
+
columnsMobile="1fr"
|
|
193
|
+
gap
|
|
194
|
+
>
|
|
195
|
+
{features.map((item, index) => (
|
|
196
|
+
<Card key={index}>
|
|
197
|
+
<Text faint>{item.icon}</Text>
|
|
198
|
+
<Spacer height="5px" />
|
|
199
|
+
<Heading top marginBottom="5px">
|
|
200
|
+
{item.title}
|
|
201
|
+
</Heading>
|
|
202
|
+
<Text muted>{item.text}</Text>
|
|
203
|
+
</Card>
|
|
204
|
+
))}
|
|
205
|
+
</Grid>
|
|
206
|
+
</div>
|
|
207
|
+
</Page>
|
|
208
|
+
);
|
|
209
|
+
};
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
/*
|
|
2
|
+
This helper allows us to export simple LESS variables as JavaScript objects.
|
|
3
|
+
The intention is for keeping code DRY by allowing primary colour palettes etc
|
|
4
|
+
to be defined in one place only (LESS).
|
|
5
|
+
|
|
6
|
+
These simple variables should be defined in a files called `shared.less` that
|
|
7
|
+
can exist in one of two place:
|
|
8
|
+
|
|
9
|
+
- in `override.less` in the root of the parent project
|
|
10
|
+
(to allow overriding of the default values set in this project)
|
|
11
|
+
- in `src/style/shared.less in this project (default values)
|
|
12
|
+
|
|
13
|
+
The parent and local definitions are merged, with the parent taking
|
|
14
|
+
precedence.
|
|
15
|
+
|
|
16
|
+
The implementation uses Webpack raw-loader to load the shared LESS variables
|
|
17
|
+
file, and a 3rd party package (less-vars-to-js) to parse it, so they can be
|
|
18
|
+
exported for use in JavaScript.
|
|
19
|
+
|
|
20
|
+
When we upgrade to Webpack 5, we'll have to refactor this to use asset modules
|
|
21
|
+
instead.
|
|
22
|
+
*/
|
|
23
|
+
|
|
24
|
+
import lessToJs from 'less-vars-to-js';
|
|
25
|
+
|
|
26
|
+
// eslint-disable-next-line import/no-unresolved,import/no-webpack-loader-syntax
|
|
27
|
+
import lessVariables from '../style/shared.less?raw';
|
|
28
|
+
|
|
29
|
+
/*
|
|
30
|
+
We need to import the `shared.less` file from the root of the parent project
|
|
31
|
+
conditionally (it may not exist). Would love to use ES6 imports here, but they
|
|
32
|
+
don't allow optional files without throwing an error when the file doesn't
|
|
33
|
+
exist. ES6 dynamic imports would require `async` when we use this helper
|
|
34
|
+
(prefer to avoid that). So falling back to CommonJS require here.
|
|
35
|
+
|
|
36
|
+
Hopefully this will get better once we have Webpack 5 asset modules.
|
|
37
|
+
*/
|
|
38
|
+
let lessParentVariables = '{}';
|
|
39
|
+
try {
|
|
40
|
+
const parentPath = '../../../../override.less?raw';
|
|
41
|
+
// eslint-disable-next-line import/no-unresolved,global-require,import/no-webpack-loader-syntax,import/no-dynamic-require
|
|
42
|
+
lessParentVariables = require(`${parentPath}`).default;
|
|
43
|
+
} catch (e) {
|
|
44
|
+
//do nothing (we fallback to the local definition anyway)
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
const load = () => {
|
|
48
|
+
/*
|
|
49
|
+
Merge the parent project shared.less with the local shared.less
|
|
50
|
+
(since less-vars-to-js doesn't handle import statements for us)
|
|
51
|
+
|
|
52
|
+
The parent definition takes precedence over the local definition
|
|
53
|
+
*/
|
|
54
|
+
const parent = lessToJs(lessParentVariables, {
|
|
55
|
+
resolveVariables: true,
|
|
56
|
+
stripPrefix: true,
|
|
57
|
+
});
|
|
58
|
+
const local = lessToJs(lessVariables, {
|
|
59
|
+
resolveVariables: true,
|
|
60
|
+
stripPrefix: true,
|
|
61
|
+
});
|
|
62
|
+
return {
|
|
63
|
+
...local,
|
|
64
|
+
...parent,
|
|
65
|
+
};
|
|
66
|
+
};
|
|
67
|
+
|
|
68
|
+
export const styleVariables = load();
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { useEffect } from 'react';
|
|
2
|
+
|
|
3
|
+
export const useKeyboardEvent = (key, fn, dependencyList = []) => {
|
|
4
|
+
useEffect(() => {
|
|
5
|
+
const handler = (event) => {
|
|
6
|
+
if (event.key === key) {
|
|
7
|
+
fn();
|
|
8
|
+
}
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
window.addEventListener('keydown', handler);
|
|
12
|
+
return () => {
|
|
13
|
+
window.removeEventListener('keydown', handler);
|
|
14
|
+
};
|
|
15
|
+
}, dependencyList);
|
|
16
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { debounce } from 'lodash';
|
|
2
|
+
import { useState, useEffect } from 'react';
|
|
3
|
+
|
|
4
|
+
const getWidth = () =>
|
|
5
|
+
window.innerWidth ||
|
|
6
|
+
document.documentElement.clientWidth ||
|
|
7
|
+
document.body.clientWidth;
|
|
8
|
+
|
|
9
|
+
//https://dev.to/vitaliemaldur/resize-event-listener-using-react-hooks-1k0c
|
|
10
|
+
export const useWindowWidth = () => {
|
|
11
|
+
let [width, setWidth] = useState(getWidth());
|
|
12
|
+
const resizeListener = debounce(() => setWidth(getWidth()), 150);
|
|
13
|
+
useEffect(() => {
|
|
14
|
+
window.addEventListener('resize', resizeListener);
|
|
15
|
+
return () => {
|
|
16
|
+
window.removeEventListener('resize', resizeListener);
|
|
17
|
+
};
|
|
18
|
+
}, []);
|
|
19
|
+
return width;
|
|
20
|
+
};
|
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
<?xml version="1.0"?>
|
|
2
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 30 30" width="30px" height="30px">
|
|
3
|
+
<path fill="currentColor" d="M 5 4 C 4.448 4 4 4.448 4 5 L 4 9 C 4 9.256 4.0979687 9.5120312 4.2929688 9.7070312 C 4.6829687 10.098031 5.3160312 10.098031 5.7070312 9.7070312 L 7 8.4140625 L 11.414062 12.828125 C 11.789924 13.203987 12 13.710844 12 14.242188 L 12 20 A 1.0001 1.0001 0 1 0 14 20 L 14 14.242188 C 14 13.181531 13.578263 12.164202 12.828125 11.414062 L 8.4140625 7 L 9.7070312 5.7070312 C 10.098031 5.3170313 10.098031 4.6839688 9.7070312 4.2929688 C 9.5120312 4.0979687 9.256 4 9 4 L 5 4 z M 21 4 C 20.744 4 20.487969 4.0979687 20.292969 4.2929688 C 19.901969 4.6839688 19.901969 5.3170313 20.292969 5.7070312 L 21.585938 7 L 17.171875 11.414062 C 16.421737 12.164202 16 13.18153 16 14.242188 L 16 20 A 1.0001 1.0001 0 1 0 18 20 L 18 14.242188 C 18 13.710843 18.210076 13.203987 18.585938 12.828125 L 23 8.4140625 L 24.292969 9.7070312 C 24.683969 10.098031 25.317031 10.098031 25.707031 9.7070312 C 25.902031 9.5120312 26 9.256 26 9 L 26 5 C 26 4.448 25.552 4 25 4 L 21 4 z M 4.984375 12.986328 A 1.0001 1.0001 0 0 0 4 14 L 4 24 C 4 25.093063 4.9069372 26 6 26 L 24 26 C 25.093063 26 26 25.093063 26 24 L 26 14 A 1.0001 1.0001 0 1 0 24 14 L 24 24 L 6 24 L 6 14 A 1.0001 1.0001 0 0 0 4.984375 12.986328 z"/>
|
|
4
|
+
</svg>
|
|
Binary file
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<svg width="300px" height="116px" viewBox="0 0 300 116" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
|
3
|
+
<title>logo</title>
|
|
4
|
+
<g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
|
|
5
|
+
<g id="Group">
|
|
6
|
+
<rect id="Rectangle" fill="#FF6600" x="0" y="7.10542736e-15" width="300" height="116.363636" rx="14.5454545"></rect>
|
|
7
|
+
<text id="LOGO" font-family="LucidaGrande-Bold, Lucida Grande" font-size="87.2727273" font-weight="bold" fill="#FFFFFF">
|
|
8
|
+
<tspan x="19.3323864" y="89.4545455">LOGO</tspan>
|
|
9
|
+
</text>
|
|
10
|
+
<ellipse id="Oval" fill="#FFFFFF" cx="241.818182" cy="58.1818182" rx="20" ry="27.2727273"></ellipse>
|
|
11
|
+
</g>
|
|
12
|
+
</g>
|
|
13
|
+
</svg>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<svg height="60" viewBox="0 0 735 60" width="735" xmlns="http://www.w3.org/2000/svg"><g fill="none"><g transform="translate(.2)"><path d="m324.426253 59.8796834h-294.4864113c-16.3733509 0-29.9398417-13.3325858-29.9398417-29.9398417 0-16.3733509 13.3325858-29.9398417 29.9398417-29.9398417h294.7203163c16.373351 0 29.939842 13.3325858 29.939842 29.9398417-.233905 16.6072559-13.566491 29.9398417-30.173747 29.9398417z" fill="#eb662b"/><g fill="#fff" transform="translate(23.156596 18.946306)"><path d="m225.952243 11.4613456c0-.93562.233905-1.40343.701715-1.63733505.46781-.23390501 1.40343-.46781002 2.33905-.46781002h32.746702c.701715 0 1.169525.23390501 1.637335.70171507.46781.46781.701715.93562.701715 1.6373351 0 .701715-.233905 1.169525-.701715 1.6373351-.46781.46781-.93562.701715-1.637335.701715h-31.109367v5.8476253c0 .7017151-.233905 1.1695251-.701715 1.6373351s-.93562.7017151-1.637335.7017151-1.169525-.2339051-1.637335-.7017151-.701715-.93562-.701715-1.6373351z"/><path d="m39.0621372 7.95277045c-.46781-1.16952507-.93562-2.33905013-1.6373351-3.27467019-.701715-.93562005-1.6373351-1.8712401-2.5729551-2.57295514-.9356201-.70171504-2.3390502-.93562005-3.5085752-1.16952507h-22.22097629c-1.40343007 0-2.57295514.23390502-3.74248021.93562006-1.16952506.70171504-2.10514512 1.40343007-2.80686015 2.57295514-.70171504.93562005-1.40343008 2.10514512-1.87124011 3.5085752-.46781003 1.16952506-.70171504 2.57295515-.70171504 3.74248025 0 1.169525.23390501 2.3390501.46781003 3.7424802.46781002 1.169525.93562005 2.3390501 1.63733509 3.2746702.70171504.93562 1.63733509 1.8712401 2.57295514 2.5729551.93562006.701715 2.10514512.9356201 3.5085752 1.1695251h22.22097624c1.4034301 0 2.5729552-.233905 3.7424802-.9356201 1.1695251-.701715 2.1051451-1.4034301 2.8068602-2.5729551.701715-.9356201 1.4034301-2.1051452 1.8712401-3.5085752.46781-1.1695251.701715-2.5729552.701715-3.7424802.233905-1.1695251 0-2.57295519-.46781-3.74248025zm-4.2102902 5.61372035c-.233905.701715-.4678101 1.40343-.9356201 1.8712401-.46781.46781-.93562 1.169525-1.6373351 1.40343-.701715.4678101-1.6373351.7017151-2.8068601.7017151h-19.64802115c-1.16952506 0-2.10514511-.233905-2.80686015-.7017151-.70171504-.46781-1.16952507-.93562-1.6373351-1.40343-.46781002-.4678101-.70171504-1.1695251-.93562005-1.8712401-.23390501-.7017151-.23390501-1.4034301-.23390501-1.8712401 0-.4678101 0-1.1695251.23390501-1.87124015.23390501-.70171504.46781003-1.40343008.93562005-1.8712401.46781003-.46781003.93562006-1.16952507 1.6373351-1.40343008.70171504-.46781003 1.63733509-.70171504 2.80686015-.70171504h19.64802115c1.169525 0 2.1051451.23390501 2.8068601.70171504.7017151.46781003 1.1695251.93562005 1.6373351 1.40343008.46781.46781002.7017151 1.16952506.9356201 1.8712401.233905.70171505.233905 1.40343005.233905 1.87124015 0 .46781 0 1.169525-.233905 1.8712401z"/><path d="m101.046966 21.2853562c-.46781.46781-1.1695254.9356201-1.8712404.9356201s-1.1695251-.2339051-1.6373351-.7017151-.701715-.93562-.701715-1.6373351c0-.46781.233905-1.169525.46781-1.4034301l11.9291555-15.90554085c.46781-.70171504 1.169525-1.40343008 2.105145-1.87124011s1.87124-.70171504 2.80686-.70171504 1.871241.23390501 2.806861.70171504 1.637335.93562005 2.105145 1.63733509l11.929155 15.90554087c.233905.233905.46781.4678101.46781.7017151.233905.233905.233905.46781.233905.93562 0 .7017151-.233905 1.1695251-.701715 1.6373351s-.93562.7017151-1.637335.7017151-1.40343-.2339051-1.87124-.9356201l-11.22744-15.20382586c-.233905-.23390501-.46781-.46781002-.93562-.93562005-.233906-.23390501-.701716-.46781003-.935621-.46781003-.46781 0-.701715.23390502-.93562.46781003s-.701715.70171504-.701715.93562005z"/><path d="m92.1585752 19.8819261c0 .7017151-.233905 1.1695251-.701715 1.6373351-.4678101.46781-.9356201.7017151-1.6373351.7017151-.7017151 0-1.1695251-.2339051-1.6373351-.7017151-.4678101-.46781-.7017151-.93562-.7017151-1.6373351v-16.60725592c0-.70171503.233905-1.16952506.7017151-1.63733509.46781-.46781002.93562-.70171504 1.6373351-.70171504.701715 0 1.169525.23390502 1.6373351.70171504.46781.46781003.701715.93562006.701715 1.63733509z"/><path d="m51.2251979 22.2209763c-.9356201 0-1.8712401-.2339051-2.5729552-.4678101-.701715-.233905-1.40343-.701715-2.1051451-1.4034301-.701715-.46781-1.169525-1.169525-1.4034301-2.1051451-.46781-.701715-.46781-1.6373351-.46781-2.5729551v-12.39696572c0-.70171503.233905-1.16952506.7017151-1.63733509.46781-.46781002.93562-.70171504 1.6373351-.70171504.701715 0 1.169525.23390502 1.637335.70171504.4678101.46781003.7017151.93562006.7017151 1.63733509v12.39696572c0 .46781.233905.93562.46781 1.169525.46781.4678101.701715.4678101 1.4034301.4678101h29.2381266c.7017151 0 1.1695251.233905 1.6373351.701715.4678101.46781.7017151.9356201.7017151 1.6373351s-.233905 1.1695251-.7017151 1.6373351c-.46781.46781-.93562.701715-1.6373351.701715h-29.2381266z"/><path d="m225.952243 3.27467018c0-.70171503.233905-1.16952506.701715-1.63733509.46781-.46781002.93562-.70171504 1.637335-.70171504h34.384037c.701715 0 1.169525.23390502 1.637335.70171504.46781.46781003.701715.93562006.701715 1.63733509 0 .70171504-.233905 1.16952507-.701715 1.6373351-.46781.46781002-.93562.70171504-1.637335.70171504h-34.384037c-.701715 0-1.169525-.23390502-1.637335-.70171504-.701715-.46781003-.701715-.93562006-.701715-1.6373351z"/><path d="m220.338522 7.95277045c-.46781-1.16952507-.93562-2.33905013-1.637335-3.27467019-.701715-.93562005-1.637335-1.8712401-2.572955-2.57295514s-2.33905-.93562005-3.508575-1.16952507h-22.220976c-1.40343 0-2.572955.23390502-3.74248.93562006-1.169526.70171504-2.105146 1.40343007-2.806861 2.57295514-.701715.93562005-1.40343 2.10514512-1.87124 3.5085752-.46781 1.16952506-.701715 2.57295515-.701715 3.74248025 0 1.169525.233905 2.3390501.46781 3.7424802.46781 1.169525.93562 2.3390501 1.637335 3.2746702.701715.93562 1.637335 1.8712401 2.572955 2.5729551.935621.701715 2.339051.9356201 3.508576 1.1695251h22.220976c1.40343 0 2.572955-.233905 3.74248-.9356201 1.169525-.701715 2.105145-1.4034301 2.80686-2.5729551.701715-.9356201 1.40343-2.1051452 1.87124-3.5085752.46781-1.1695251.701715-2.5729552.701715-3.7424802.233905-1.1695251 0-2.57295519-.46781-3.74248025zm-4.21029 5.61372035c-.233905.701715-.46781 1.40343-.93562 1.8712401-.46781.46781-.93562 1.169525-1.637335 1.40343-.701715.4678101-1.637335.7017151-2.80686.7017151h-19.648021c-1.169525 0-2.105145-.233905-2.80686-.7017151-.701715-.46781-1.169525-.93562-1.637335-1.40343-.46781-.4678101-.701716-1.1695251-.935621-1.8712401-.233905-.7017151-.233905-1.4034301-.233905-1.8712401 0-.4678101 0-1.1695251.233905-1.87124015.233905-.70171504.467811-1.40343008.935621-1.8712401.46781-.46781003.93562-1.16952507 1.637335-1.40343008s1.637335-.70171504 2.80686-.70171504h19.648021c1.169525 0 2.105145.23390501 2.80686.70171504s1.169525.93562005 1.637335 1.40343008c.46781.46781002.701715 1.16952506.93562 1.8712401.233905.70171505.233905 1.40343005.233905 1.87124015 0 .46781 0 1.169525-.233905 1.8712401z"/><path d="m143.149868 14.0343008c-.93562 0-1.637335-.233905-2.572955-.46781-.701715-.233905-1.40343-.7017151-2.105145-1.4034301-.46781-.46781-.93562-1.1695251-1.40343-2.1051451-.233905-.70171507-.46781-1.63733513-.46781-2.57295518s.233905-1.63733509.46781-2.57295514c.233905-.70171504.701715-1.40343008 1.40343-2.10514512.46781-.46781003 1.169525-.93562005 2.105145-1.40343008.701715-.23390501 1.637335-.46781003 2.572955-.46781003h29.472032c.701715 0 1.169525.23390502 1.637335.70171504.46781.46781003.701715.93562006.701715 1.63733509 0 .70171504-.233905 1.16952507-.701715 1.6373351-.46781.46781002-.93562.70171504-1.637335.70171504h-29.705937c-.46781 0-.93562.23390501-1.40343.46781002-.46781.23390502-.46781.70171504-.46781 1.40343008 0 .46781003.233905.93562005.46781 1.16952507.46781.46781002.701715.46781002 1.40343.46781002h26.899077c.93562 0 1.87124.23390502 2.572955.46781003s1.40343.70171506 2.105145 1.40343006c.46781.46781.93562 1.1695251 1.40343 2.1051451.233905.7017151.46781 1.6373351.46781 2.5729552 0 .93562-.233905 1.6373351-.46781 2.5729551-.233905.7017151-.701715 1.4034301-1.40343 2.1051451-.46781.4678101-1.169525.9356201-2.105145 1.4034301-.701715.233905-1.637335.4678101-2.572955.4678101h-29.472032c-.701715 0-1.169525-.2339051-1.637335-.7017151s-.701715-.93562-.701715-1.6373351c0-.701715.233905-1.169525.701715-1.6373351.46781-.46781.93562-.701715 1.637335-.701715h29.705937c.46781 0 .93562-.233905 1.169525-.46781.46781-.2339051.46781-.7017151.46781-1.1695251s-.233905-.9356201-.46781-1.4034301c-.46781-.46781-.701715-.46781-1.169525-.46781z"/><path d="m305.713852.93562005c.701715 0 1.169525.23390502 1.637335.70171504.46781.46781003.701715.93562006.701715 1.63733509 0 .70171504-.233905 1.16952507-.701715 1.6373351-.46781.46781002-.93562.70171504-1.637335.70171504h-14.502111v14.26820578c0 .7017151-.233905 1.1695251-.701715 1.6373351s-.93562.7017151-1.637335.7017151-1.169525-.2339051-1.637335-.7017151-.701715-.93562-.701715-1.6373351v-14.26820578h-14.502111c-.46781 0-1.169525-.23390502-1.40343-.70171504-.46781-.46781003-.701715-.93562006-.701715-1.6373351 0-.70171503.233905-1.16952506.701715-1.63733509.46781-.46781002.93562-.70171504 1.637335-.70171504z"/></g></g><g fill="currentColor" transform="translate(370.2 9)"><path d="m0 .74282797h9.56391016l1.20709544 21.63486473c.0928535 3.4355794.185707 6.4997448.185707 10.2138846h.185707c.557121-3.6212863 1.299949-6.7783052 1.9499234-10.1210311l2.6927514-11.3281266h5.8497703l2.5998979 11.3281266c.6499745 3.3427259 1.3928025 6.4068913 1.9499235 10.1210311h.2785605c.0928535-3.7141398.0928535-6.7783052.1857069-10.1210311l1.114242-21.63486473h8.9139357l-4.8283818 40.48412453h-9.8424707l-2.4141909-12.535222c-.4642675-2.5998979-.928535-5.2926493-1.114242-7.7068403h-.185707c-.2785604 2.414191-.5571209 5.1997959-1.1142419 7.7068403l-2.2284839 12.535222h-9.56391019z"/><path d="m42.805462.74282797h26.8346605v7.70684023h-17.6421644v8.1711077h15.0422665v7.7068402h-15.0422665v9.2853497h18.2921389v7.7068402h-27.484635z"/><path d="m78.5540582.74282797h9.1924962v32.87013783h18.0135786v7.7068402h-27.2060748z"/><path d="m113.374119.74282797h9.192497v32.87013783h18.013578v7.7068402h-27.206075z"/><path d="m148.472741.74282797h11.235273c11.792394 0 19.499235 6.12833078 19.499235 20.05635533 0 13.9280245-7.706841 20.4277692-18.942114 20.4277692h-11.69954v-40.48412453zm10.678152 33.14869833c6.314038 0 10.585299-3.3427259 10.585299-13.092343 0-9.6567637-4.271261-12.72092909-10.585299-12.72092909h-1.485656v25.81327209z"/><path d="m187.099796.74282797h26.83466v7.70684023h-17.735018v8.1711077h15.042267v7.7068402h-15.042267v9.2853497h18.292139v7.7068402h-27.484635v-40.57697803z"/><path d="m221.827004 36.2128637 5.292649-6.3140378c3.064165 2.5070444 6.871159 4.2712609 10.771005 4.2712609 3.899847 0 5.664064-1.485656 5.664064-3.5284329 0-2.8784584-2.414191-3.6212864-6.221184-5.1997958l-5.29265-2.2284839c-4.456968-1.671363-8.635375-5.1069423-8.635375-11.0495661 0-6.6854518 6.035477-12.0709546 14.856559-12.0709546 4.921236 0 9.842471 1.85706993 13.463758 5.29264931l-4.642675 5.75691679c-2.878459-2.04277693-5.385503-3.15701889-9.378203-3.15701889-3.064166 0-5.106943 1.20709546-5.106943 3.62128639 0 2.4141909 2.692752 3.3427259 6.592598 4.8283818l4.921236 2.1356304c5.292649 1.9499235 8.635375 5.2926493 8.635375 11.0495661 0 6.7783053-5.664063 12.5352221-15.692241 12.5352221-5.199796-.0928535-10.863859-2.1356304-15.227973-5.9426238z"/><path d="m260.639765 33.6129658h9.471057v-25.1632976h-9.471057v-7.70684023h28.13461v7.70684023h-9.471057v25.1632976h9.471057v7.7068402h-28.13461z"/><path d="m296.109801 21.2634507c0-13.55661048 8.263961-21.2634507 18.756406-21.2634507 5.478357 0 9.28535 2.50704441 11.885248 5.19979581l-5.014089 5.66406329c-1.764216-1.76421643-3.621286-2.87845839-6.778305-2.87845839-5.29265 0-9.28535 4.92123529-9.28535 12.99948959 0 8.3568147 3.249872 13.1851965 9.656764 13.1851965 1.485656 0 3.064165-.4642675 3.899847-1.2070955v-6.9640122h-5.849771v-7.5211333h14.113732v18.6635529c-2.692752 2.5070444-7.521133 4.9212353-12.720929 4.9212353-10.399592 0-18.663553-7.1497192-18.663553-20.7991833z"/><path d="m334.829709.74282797h9.378203l8.542522 20.14920883 3.435579 8.9139356h.185707c-.371414-4.2712608-1.299949-9.9353241-1.299949-14.7637059v-14.29943853h8.728229v40.57697803h-9.378203l-8.542522-20.2420623-3.435579-8.8210821h-.185707c.371414 4.4569678 1.299949 9.9353241 1.299949 14.6708524v14.392292h-8.728229z"/></g></g></svg>
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
@import './shared.less';
|
|
2
|
+
|
|
3
|
+
.generate-color-range(@name, @color, @saturationOffset: 0) {
|
|
4
|
+
@selectors: range(0, 1000, 50);
|
|
5
|
+
@hue: hue(@color);
|
|
6
|
+
@saturation: saturation(@color) + @saturationOffset;
|
|
7
|
+
each(@selectors, {
|
|
8
|
+
@lightness: 100% - (@value / 10) + 2.5;
|
|
9
|
+
--color-@{name}-@{value}: hsl(@hue, @saturation, @lightness) ;
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
:root {
|
|
14
|
+
.generate-color-range(primary, @color: @colorPrimary);
|
|
15
|
+
.generate-color-range(error, @color: @colorError);
|
|
16
|
+
.generate-color-range(success, @color: @colorSuccess);
|
|
17
|
+
.generate-color-range(warning, @color: @colorWarning);
|
|
18
|
+
.generate-color-range(info, @color: @colorInfo);
|
|
19
|
+
.generate-color-range(neutral, @color: @colorNeutral, @saturationOffset: -15%);
|
|
20
|
+
|
|
21
|
+
.generate-color-range(primary-muted, @color: @colorPrimary, @saturationOffset: -25%);
|
|
22
|
+
.generate-color-range(error-muted, @color: @colorError, @saturationOffset: -25%);
|
|
23
|
+
.generate-color-range(success-muted, @color: @colorSuccess, @saturationOffset: -25%);
|
|
24
|
+
.generate-color-range(warning-muted, @color: @colorWarning, @saturationOffset: -25%);
|
|
25
|
+
.generate-color-range(info-muted, @color: @colorInfo, @saturationOffset: -25%);
|
|
26
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
@import './fonts.less';
|
|
2
|
+
@import './reset/reset.less';
|
|
3
|
+
|
|
4
|
+
@import '../components/top-bar/top-bar.module.less';
|
|
5
|
+
@import '../components/form/form.module.less';
|
|
6
|
+
@import '../components/card/card.module.less';
|
|
7
|
+
@import '../components/button/button.module.less';
|
|
8
|
+
@import '../components/check-box/check-box.module.less';
|
|
9
|
+
@import '../components/input/input.module.less';
|
|
10
|
+
@import '../components/message/message.module.less';
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
@font-face {
|
|
2
|
+
font-family: 'Lato';
|
|
3
|
+
font-weight: normal;
|
|
4
|
+
font-style: normal;
|
|
5
|
+
src: url('./fonts/lato/Lato-Regular.woff2') format('woff2');
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
@font-face {
|
|
9
|
+
font-family: 'Lato';
|
|
10
|
+
font-weight: bold;
|
|
11
|
+
font-style: normal;
|
|
12
|
+
src: url('./fonts/lato/Lato-Bold.woff2') format('woff2');
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
@font-face {
|
|
16
|
+
font-family: 'Lato';
|
|
17
|
+
font-weight: normal;
|
|
18
|
+
font-style: italic;
|
|
19
|
+
src: url('./fonts/lato/Lato-Italic.woff2') format('woff2');
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
@font-face {
|
|
23
|
+
font-family: 'Lato';
|
|
24
|
+
font-weight: bold;
|
|
25
|
+
font-style: italic;
|
|
26
|
+
src: url('./fonts/lato/Lato-BoldItalic.woff2') format('woff2');
|
|
27
|
+
}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
@import './variables.less';
|
|
2
|
+
@import './fonts.less';
|
|
3
|
+
@import './reset/reset.less';
|
|
4
|
+
|
|
5
|
+
@import '../components/form/form.module.less';
|
|
6
|
+
|
|
7
|
+
html {
|
|
8
|
+
font-size: 14px;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
body {
|
|
12
|
+
color: var(--color-text);
|
|
13
|
+
// background-color: var(--color-background);
|
|
14
|
+
line-height: 1.4285em;
|
|
15
|
+
font-family: @default_font;
|
|
16
|
+
font-size: 14px;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
.dark {
|
|
20
|
+
color: var(--color-text);
|
|
21
|
+
// background-color: var(--color-background);
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
h1,
|
|
25
|
+
h2,
|
|
26
|
+
h3,
|
|
27
|
+
h4,
|
|
28
|
+
h5 {
|
|
29
|
+
line-height: 1.285714em;
|
|
30
|
+
margin: 0 0 1rem;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
p,
|
|
34
|
+
ul,
|
|
35
|
+
ol {
|
|
36
|
+
margin: 0 0 1rem;
|
|
37
|
+
line-height: 1.4285em;
|
|
38
|
+
|
|
39
|
+
&:last-child {
|
|
40
|
+
margin-bottom: 0;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
ul,
|
|
45
|
+
ol {
|
|
46
|
+
padding-left: 1.5em;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
a {
|
|
50
|
+
text-decoration: none;
|
|
51
|
+
}
|