blue-react 8.0.0-next.3 → 8.0.0-next.4

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.
Files changed (36) hide show
  1. package/README.md +59 -59
  2. package/dist/components/ActionMenuSwitch.js +2 -2
  3. package/dist/components/Caret.js +2 -2
  4. package/dist/components/DocumentView.js +3 -3
  5. package/dist/components/Grid.js +275 -275
  6. package/dist/components/Header.js +2 -2
  7. package/dist/components/HeaderTitle.js +3 -3
  8. package/dist/components/Intro.js +2 -2
  9. package/dist/components/Layout.js +7 -0
  10. package/dist/components/Outside.js +6 -6
  11. package/dist/components/Page.js +2 -2
  12. package/dist/components/SidebarMenu.js +2 -2
  13. package/dist/components/Switch.js +2 -2
  14. package/dist/style.css +9 -9
  15. package/dist/style.min.css +7 -7
  16. package/dist/style.scss +1 -1
  17. package/dist/styles/_action-menu.scss +81 -81
  18. package/dist/styles/_bootstrap-mixins_overwritten.scss +106 -106
  19. package/dist/styles/_bootstrap-optimizations.scss +13 -13
  20. package/dist/styles/_bootstrap-variables.scss +13 -13
  21. package/dist/styles/_bootstrap.scss +56 -56
  22. package/dist/styles/_caret.scss +50 -50
  23. package/dist/styles/_document-view.scss +6 -6
  24. package/dist/styles/_hover.scss +42 -42
  25. package/dist/styles/_keyframes.scss +73 -73
  26. package/dist/styles/_mixins.scss +6 -6
  27. package/dist/styles/_router.scss +18 -18
  28. package/dist/styles/_switch.scss +21 -21
  29. package/dist/styles/mixins/_action-menu.scss +68 -68
  30. package/dist/styles/mixins/_custom-property.scss +10 -10
  31. package/dist/styles/mixins/_misc.scss +33 -33
  32. package/dist/styles/mixins/_scroll-shadow.scss +9 -9
  33. package/dist/styles/mixins/_sidebar.scss +142 -142
  34. package/dist/styles/mixins/_switch.scss +85 -85
  35. package/dist/types/components/Layout.d.ts +1 -0
  36. package/package.json +88 -88
@@ -1,142 +1,142 @@
1
- @mixin openSidebarMenu() {
2
- .blue-sidebar-hidden-on-open {
3
- display: none;
4
- }
5
-
6
- .blue-sidebar-visible-on-open {
7
- animation: fade-in 1s;
8
- display: flex;
9
- }
10
-
11
- .blue-menu-item-label {
12
- display: inline-block;
13
- }
14
-
15
- .blue-sidebar {
16
- z-index: 42;
17
- box-shadow: 0.6rem 6rem 6rem rgba(0, 0, 0, 0.4);
18
- // background-color: darken($theme, 30%);
19
- }
20
-
21
- .blue-sidebar,
22
- .blue-sidebar .blue-menu-item {
23
- width: $bla-sidebar-width;
24
- }
25
-
26
- .blue-sidebar .blue-menu-item {
27
- & > * {
28
- width: auto;
29
- }
30
- }
31
-
32
- .blue-sub-sidebar {
33
- left: $bla-sidebar-width;
34
- }
35
-
36
- .blue-menu-item-dropdown-caret.caret {
37
- display: flex;
38
- }
39
-
40
- .blue-menu-item-dropdown {
41
- .blue-menu-item {
42
- width: 100%;
43
- }
44
- }
45
-
46
- /* search */
47
- .blue-search {
48
- background-color: $sidebar-search-bg;
49
- }
50
-
51
- .blue-search-btn {
52
- display: none;
53
- }
54
-
55
- .blue-search-input-group {
56
- display: flex;
57
- align-items: center;
58
- }
59
-
60
- .blue-header-logo.sidebar {
61
- transform: translateX(0);
62
- }
63
- }
64
-
65
- @mixin blue-sidebar($width) {
66
- .blue-menu-item {
67
- color: $sidebar-color;
68
- width: $normal-size;
69
- height: $normal-size;
70
- padding: 0.25rem 0.75rem;
71
- font-size: $bla-btn-font-size;
72
- display: flex;
73
- align-items: center;
74
- border-color: transparent;
75
- @include slide-transition();
76
-
77
- &:hover,
78
- &:active {
79
- color: $sidebar-color;
80
- background-color: $sidebar-control-bg-hover !important;
81
- border-color: transparent;
82
- }
83
-
84
- &.active::before {
85
- content: "";
86
- position: absolute;
87
- top: 0.625rem;
88
- bottom: 0.625rem;
89
- left: 0;
90
- width: 0.25rem;
91
- background-color: $sidebar-indicator-color;
92
- border-top-right-radius: 1rem;
93
- border-bottom-right-radius: 1rem;
94
- animation: sidebar-menu-item-indicator-in 0.2s ease-in-out;
95
- }
96
-
97
- & > * + .blue-menu-item-label {
98
- margin-left: 0.5rem;
99
- }
100
- }
101
-
102
- .blue-sidebar {
103
- width: $width;
104
- color: $sidebar-color;
105
- background: var(--sidebar-bg);
106
- position: fixed;
107
- left: 0;
108
- top: $normal-size;
109
- bottom: 0;
110
- z-index: 3;
111
- display: flex;
112
- flex-direction: column;
113
- @include slide-transition();
114
-
115
- .blue-menu {
116
- overflow-y: auto;
117
- flex: 1;
118
- @include scroll-shadow(var(--sidebar-bg), $sidebar-bg);
119
- }
120
-
121
- &:hover {
122
- .blue-menu-item {
123
- background-color: var(--sidebar-bg);
124
- }
125
- }
126
-
127
- .blue-menu-item {
128
- & > * {
129
- width: 100%;
130
- }
131
- }
132
- }
133
- }
134
-
135
- @keyframes sidebar-menu-item-indicator-in {
136
- from {
137
- transform: translateX(-100%);
138
- }
139
- to {
140
- transform: translateX(1);
141
- }
142
- }
1
+ @mixin openSidebarMenu() {
2
+ .blue-sidebar-hidden-on-open {
3
+ display: none;
4
+ }
5
+
6
+ .blue-sidebar-visible-on-open {
7
+ animation: fade-in 1s;
8
+ display: flex;
9
+ }
10
+
11
+ .blue-menu-item-label {
12
+ display: inline-block;
13
+ }
14
+
15
+ .blue-sidebar {
16
+ z-index: 42;
17
+ box-shadow: 0.6rem 6rem 6rem rgba(0, 0, 0, 0.4);
18
+ // background-color: darken($theme, 30%);
19
+ }
20
+
21
+ .blue-sidebar,
22
+ .blue-sidebar .blue-menu-item {
23
+ width: $bla-sidebar-width;
24
+ }
25
+
26
+ .blue-sidebar .blue-menu-item {
27
+ & > * {
28
+ width: auto;
29
+ }
30
+ }
31
+
32
+ .blue-sub-sidebar {
33
+ left: $bla-sidebar-width;
34
+ }
35
+
36
+ .blue-menu-item-dropdown-caret.caret {
37
+ display: flex;
38
+ }
39
+
40
+ .blue-menu-item-dropdown {
41
+ .blue-menu-item {
42
+ width: 100%;
43
+ }
44
+ }
45
+
46
+ /* search */
47
+ .blue-search {
48
+ background-color: $sidebar-search-bg;
49
+ }
50
+
51
+ .blue-search-btn {
52
+ display: none;
53
+ }
54
+
55
+ .blue-search-input-group {
56
+ display: flex;
57
+ align-items: center;
58
+ }
59
+
60
+ .blue-header-logo.sidebar {
61
+ transform: translateX(0);
62
+ }
63
+ }
64
+
65
+ @mixin blue-sidebar($width) {
66
+ .blue-menu-item {
67
+ color: $sidebar-color;
68
+ width: $normal-size;
69
+ height: $normal-size;
70
+ padding: 0.25rem 0.75rem;
71
+ font-size: $bla-btn-font-size;
72
+ display: flex;
73
+ align-items: center;
74
+ border-color: transparent;
75
+ @include slide-transition();
76
+
77
+ &:hover,
78
+ &:active {
79
+ color: $sidebar-color;
80
+ background-color: $sidebar-control-bg-hover !important;
81
+ border-color: transparent;
82
+ }
83
+
84
+ &.active::before {
85
+ content: "";
86
+ position: absolute;
87
+ top: 0.625rem;
88
+ bottom: 0.625rem;
89
+ left: 0;
90
+ width: 0.25rem;
91
+ background-color: $sidebar-indicator-color;
92
+ border-top-right-radius: 1rem;
93
+ border-bottom-right-radius: 1rem;
94
+ animation: sidebar-menu-item-indicator-in 0.2s ease-in-out;
95
+ }
96
+
97
+ & > * + .blue-menu-item-label {
98
+ margin-left: 0.5rem;
99
+ }
100
+ }
101
+
102
+ .blue-sidebar {
103
+ width: $width;
104
+ color: $sidebar-color;
105
+ background: var(--sidebar-bg);
106
+ position: fixed;
107
+ left: 0;
108
+ top: $normal-size;
109
+ bottom: 0;
110
+ z-index: 3;
111
+ display: flex;
112
+ flex-direction: column;
113
+ @include slide-transition();
114
+
115
+ .blue-menu {
116
+ overflow-y: auto;
117
+ flex: 1;
118
+ @include scroll-shadow(var(--sidebar-bg), $sidebar-bg);
119
+ }
120
+
121
+ &:hover {
122
+ .blue-menu-item {
123
+ background-color: var(--sidebar-bg);
124
+ }
125
+ }
126
+
127
+ .blue-menu-item {
128
+ & > * {
129
+ width: 100%;
130
+ }
131
+ }
132
+ }
133
+ }
134
+
135
+ @keyframes sidebar-menu-item-indicator-in {
136
+ from {
137
+ transform: translateX(-100%);
138
+ }
139
+ to {
140
+ transform: translateX(1);
141
+ }
142
+ }
@@ -1,85 +1,85 @@
1
- @mixin switch(
2
- $width: 35px,
3
- $height: 20px,
4
- $padding: 3px,
5
- $color: $body-color,
6
- $color-active: $success
7
- ) {
8
- $slider-size: $height - ($padding * 2);
9
-
10
- & {
11
- position: relative;
12
- display: inline-block;
13
- width: $width;
14
- height: $height;
15
-
16
- input {
17
- display: none;
18
- }
19
-
20
- &.disabled {
21
- opacity: 0.8;
22
- }
23
-
24
- &:not(.disabled) {
25
- .slider {
26
- cursor: pointer;
27
- }
28
- }
29
-
30
- .slider {
31
- position: absolute;
32
- top: 0;
33
- left: 0;
34
- right: 0;
35
- bottom: 0;
36
- background-color: $input-group-addon-bg;
37
- transition: 0.4s;
38
- box-shadow: inset 0 0 0 1px rgba($color, 0.5);
39
-
40
- &::before {
41
- content: "";
42
- position: absolute;
43
- height: $slider-size;
44
- width: $slider-size;
45
- left: $padding;
46
- bottom: $padding;
47
- background-color: $color;
48
- transition: 0.4s;
49
- }
50
-
51
- &::after {
52
- content: attr(data-label);
53
- position: absolute;
54
- top: 50%;
55
- left: 50%;
56
- transform: translate(-50%, -50%);
57
- margin-left: ($slider-size / 2);
58
- transition: margin-left 0.4s;
59
- color: $color;
60
- }
61
- }
62
-
63
- input:checked {
64
- & + .slider {
65
- background-color: $color-active;
66
- box-shadow: inset 0 0 12px rgba(255, 255, 255, 0.3);
67
-
68
- &::before {
69
- transform: translateX(
70
- $width - $slider-size - ($padding * 2)
71
- );
72
- background-color: white;
73
- }
74
-
75
- &::after {
76
- color: white;
77
- margin-left: ($slider-size / 2) * -1;
78
- }
79
- }
80
- }
81
- input:focus + .slider {
82
- box-shadow: 0 0 1px $color-active;
83
- }
84
- }
85
- }
1
+ @mixin switch(
2
+ $width: 35px,
3
+ $height: 20px,
4
+ $padding: 3px,
5
+ $color: $body-color,
6
+ $color-active: $success
7
+ ) {
8
+ $slider-size: $height - ($padding * 2);
9
+
10
+ & {
11
+ position: relative;
12
+ display: inline-block;
13
+ width: $width;
14
+ height: $height;
15
+
16
+ input {
17
+ display: none;
18
+ }
19
+
20
+ &.disabled {
21
+ opacity: 0.8;
22
+ }
23
+
24
+ &:not(.disabled) {
25
+ .slider {
26
+ cursor: pointer;
27
+ }
28
+ }
29
+
30
+ .slider {
31
+ position: absolute;
32
+ top: 0;
33
+ left: 0;
34
+ right: 0;
35
+ bottom: 0;
36
+ background-color: $input-group-addon-bg;
37
+ transition: 0.4s;
38
+ box-shadow: inset 0 0 0 1px rgba($color, 0.5);
39
+
40
+ &::before {
41
+ content: "";
42
+ position: absolute;
43
+ height: $slider-size;
44
+ width: $slider-size;
45
+ left: $padding;
46
+ bottom: $padding;
47
+ background-color: $color;
48
+ transition: 0.4s;
49
+ }
50
+
51
+ &::after {
52
+ content: attr(data-label);
53
+ position: absolute;
54
+ top: 50%;
55
+ left: 50%;
56
+ transform: translate(-50%, -50%);
57
+ margin-left: ($slider-size * 0.5);
58
+ transition: margin-left 0.4s;
59
+ color: $color;
60
+ }
61
+ }
62
+
63
+ input:checked {
64
+ & + .slider {
65
+ background-color: $color-active;
66
+ box-shadow: inset 0 0 12px rgba(255, 255, 255, 0.3);
67
+
68
+ &::before {
69
+ transform: translateX(
70
+ $width - $slider-size - ($padding * 2)
71
+ );
72
+ background-color: white;
73
+ }
74
+
75
+ &::after {
76
+ color: white;
77
+ margin-left: ($slider-size * 0.5) * -1;
78
+ }
79
+ }
80
+ }
81
+ input:focus + .slider {
82
+ box-shadow: 0 0 1px $color-active;
83
+ }
84
+ }
85
+ }
@@ -106,5 +106,6 @@ export default class Layout extends Component<LayoutProps, LayoutState> {
106
106
  hideSidebar(e: any): void;
107
107
  initMatch(): void;
108
108
  addEventListener(param1: any, param2: any, param3: any): void;
109
+ removeEventListener(type: string, listener: any): void;
109
110
  render(): JSX.Element;
110
111
  }
package/package.json CHANGED
@@ -1,88 +1,88 @@
1
- {
2
- "name": "blue-react",
3
- "version": "8.0.0-next.3",
4
- "description": "Blue React Components",
5
- "license": "LGPL-3.0-or-later",
6
- "main": "index.js",
7
- "types": "index.d.ts",
8
- "homepage": "https://bruegmann.github.io/blue-react/v8",
9
- "repository": {
10
- "type": "git",
11
- "url": "https://github.com/bruegmann/blue-react.git"
12
- },
13
- "bugs": {
14
- "url": "https://github.com/bruegmann/blue-react/issues"
15
- },
16
- "scripts": {
17
- "start": "react-scripts start",
18
- "build-docs": "react-scripts build && npm run docgen",
19
- "build-types": "tsc --declaration --emitDeclarationOnly --declarationDir ./dist/types --noEmit false",
20
- "build": "babel ./src/components --out-dir ./dist/components --extensions \".tsx,.js,.ts\"",
21
- "build-css": "node ./setVersionToStyleScss.js && node-sass ./dist/style.scss ./dist/style.css && npx postcss ./dist/style.css --use autoprefixer -r && npx postcss ./dist/style.css --use postcss-minify -o ./dist/style.min.css",
22
- "build-release": "npm run build-types && npm run build && npm run build-css && npm run docgen",
23
- "docgen": "react-docgen ./src/components/ -o ./src/docs/data/docs.json --exclude Utilities.js --extension tsx && node followUpDocs",
24
- "test": "react-scripts test",
25
- "eject": "react-scripts eject",
26
- "predeploy": "npm run build-docs",
27
- "deploy": "gh-pages --dist build --dest v8",
28
- "prepublishOnly": "npm i && npm run build-release",
29
- "release": "npm publish --tag next && npm run deploy",
30
- "prettier": "npx prettier --write ."
31
- },
32
- "dependencies": {
33
- "@popperjs/core": "^2.10.2",
34
- "bootstrap": "^5.1.3",
35
- "clsx": "^1.1.1"
36
- },
37
- "peerDependencies": {
38
- "react": "^16.0.0 || ^17.0.0"
39
- },
40
- "devDependencies": {
41
- "@babel/cli": "^7.10.4",
42
- "@babel/preset-env": "^7.10.4",
43
- "@babel/preset-react": "^7.10.4",
44
- "@babel/preset-typescript": "^7.9.0",
45
- "@testing-library/jest-dom": "^4.2.4",
46
- "@testing-library/react": "^9.5.0",
47
- "@testing-library/user-event": "^7.2.1",
48
- "@types/bootstrap": "^5.0.17",
49
- "@types/jest": "^24.9.1",
50
- "@types/node": "^12.12.47",
51
- "@types/react": "^17.0.3",
52
- "@types/react-dom": "^17.0.3",
53
- "@types/react-router-dom": "^5.1.5",
54
- "@types/react-syntax-highlighter": "^13.5.0",
55
- "autoprefixer": "^10.3.6",
56
- "gh-pages": "^3.1.0",
57
- "lint-staged": "^11.1.2",
58
- "node-sass": "^4.14.1",
59
- "postcss-cli": "^9.0.1",
60
- "postcss-minify": "^1.1.0",
61
- "prettier": "2.4.1",
62
- "react": "^17.0.2",
63
- "react-bootstrap-icons": "^1.5.0",
64
- "react-docgen": "^5.4.0",
65
- "react-dom": "^17.0.2",
66
- "react-markdown-github": "^3.3.1",
67
- "react-router-dom": "^5.2.0",
68
- "react-scripts": "^4.0.3",
69
- "react-syntax-highlighter": "^15.4.3",
70
- "reactstrap": "^9.0.0-0",
71
- "typescript": "^4.3.5"
72
- },
73
- "eslintConfig": {
74
- "extends": "react-app"
75
- },
76
- "browserslist": {
77
- "production": [
78
- ">0.2%",
79
- "not dead",
80
- "not op_mini all"
81
- ],
82
- "development": [
83
- "last 1 chrome version",
84
- "last 1 firefox version",
85
- "last 1 safari version"
86
- ]
87
- }
88
- }
1
+ {
2
+ "name": "blue-react",
3
+ "version": "8.0.0-next.4",
4
+ "description": "Blue React Components",
5
+ "license": "LGPL-3.0-or-later",
6
+ "main": "index.js",
7
+ "types": "index.d.ts",
8
+ "homepage": "https://bruegmann.github.io/blue-react/v8",
9
+ "repository": {
10
+ "type": "git",
11
+ "url": "https://github.com/bruegmann/blue-react.git"
12
+ },
13
+ "bugs": {
14
+ "url": "https://github.com/bruegmann/blue-react/issues"
15
+ },
16
+ "scripts": {
17
+ "start": "react-scripts start",
18
+ "build-docs": "react-scripts build && npm run docgen",
19
+ "build-types": "tsc --declaration --emitDeclarationOnly --declarationDir ./dist/types --noEmit false",
20
+ "build": "babel ./src/components --out-dir ./dist/components --extensions \".tsx,.js,.ts\"",
21
+ "build-css": "node ./setVersionToStyleScss.js && node-sass ./dist/style.scss ./dist/style.css && npx postcss ./dist/style.css --use autoprefixer -r && npx postcss ./dist/style.css --use postcss-minify -o ./dist/style.min.css",
22
+ "build-release": "npm run build-types && npm run build && npm run build-css && npm run docgen",
23
+ "docgen": "react-docgen ./src/components/ -o ./src/docs/data/docs.json --exclude Utilities.js --extension tsx && node followUpDocs",
24
+ "test": "react-scripts test",
25
+ "eject": "react-scripts eject",
26
+ "predeploy": "npm run build-docs",
27
+ "deploy": "gh-pages --dist build --dest v8",
28
+ "prepublishOnly": "npm i && npm run build-release",
29
+ "release": "npm publish --tag next && npm run deploy",
30
+ "prettier": "npx prettier --write ."
31
+ },
32
+ "dependencies": {
33
+ "@popperjs/core": "^2.10.2",
34
+ "bootstrap": "^5.1.3",
35
+ "clsx": "^1.1.1"
36
+ },
37
+ "peerDependencies": {
38
+ "react": "^16.0.0 || ^17.0.0"
39
+ },
40
+ "devDependencies": {
41
+ "@babel/cli": "^7.10.4",
42
+ "@babel/preset-env": "^7.10.4",
43
+ "@babel/preset-react": "^7.10.4",
44
+ "@babel/preset-typescript": "^7.9.0",
45
+ "@testing-library/jest-dom": "^4.2.4",
46
+ "@testing-library/react": "^9.5.0",
47
+ "@testing-library/user-event": "^7.2.1",
48
+ "@types/bootstrap": "^5.0.17",
49
+ "@types/jest": "^24.9.1",
50
+ "@types/node": "^12.12.47",
51
+ "@types/react": "^17.0.3",
52
+ "@types/react-dom": "^17.0.3",
53
+ "@types/react-router-dom": "^5.1.5",
54
+ "@types/react-syntax-highlighter": "^13.5.0",
55
+ "autoprefixer": "^10.3.6",
56
+ "gh-pages": "^3.1.0",
57
+ "lint-staged": "^11.1.2",
58
+ "node-sass": "^4.14.1",
59
+ "postcss-cli": "^9.0.1",
60
+ "postcss-minify": "^1.1.0",
61
+ "prettier": "2.4.1",
62
+ "react": "^17.0.2",
63
+ "react-bootstrap-icons": "^1.5.0",
64
+ "react-docgen": "^5.4.0",
65
+ "react-dom": "^17.0.2",
66
+ "react-markdown-github": "^3.3.1",
67
+ "react-router-dom": "^5.2.0",
68
+ "react-scripts": "^4.0.3",
69
+ "react-syntax-highlighter": "^15.4.3",
70
+ "reactstrap": "^9.0.0-0",
71
+ "typescript": "^4.3.5"
72
+ },
73
+ "eslintConfig": {
74
+ "extends": "react-app"
75
+ },
76
+ "browserslist": {
77
+ "production": [
78
+ ">0.2%",
79
+ "not dead",
80
+ "not op_mini all"
81
+ ],
82
+ "development": [
83
+ "last 1 chrome version",
84
+ "last 1 firefox version",
85
+ "last 1 safari version"
86
+ ]
87
+ }
88
+ }