blue-react 9.4.2 → 9.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/HeaderTitle.js +15 -5
- package/dist/components/MenuItem.js +2 -1
- package/dist/style.css +36 -33
- package/dist/style.min.css +5 -5
- package/dist/style.scss +1 -1
- package/dist/styles/mixins/_sidebar.scss +17 -0
- package/dist/types/components/HeaderTitle.d.ts +12 -1
- package/dist/types/components/MenuItem.d.ts +3 -0
- package/package.json +2 -4
package/dist/style.scss
CHANGED
|
@@ -109,6 +109,23 @@
|
|
|
109
109
|
transition: all 0.2s;
|
|
110
110
|
}
|
|
111
111
|
|
|
112
|
+
&[draggable] {
|
|
113
|
+
cursor: move;
|
|
114
|
+
background-image: url(data:image/svg+xml,%3Csvg%20fill%3D%22currentColor%22%20class%3D%22bi%20bi-grip-vertical%22%20viewBox%3D%220%200%2016%2016%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M7%202a1%201%200%2011-2%200%201%201%200%20012%200m3%200a1%201%200%2011-2%200%201%201%200%20012%200M7%205a1%201%200%2011-2%200%201%201%200%20012%200m3%200a1%201%200%2011-2%200%201%201%200%20012%200M7%208a1%201%200%2011-2%200%201%201%200%20012%200m3%200a1%201%200%2011-2%200%201%201%200%20012%200m-3%203a1%201%200%2011-2%200%201%201%200%20012%200m3%200a1%201%200%2011-2%200%201%201%200%20012%200m-3%203a1%201%200%2011-2%200%201%201%200%20012%200m3%200a1%201%200%2011-2%200%201%201%200%20012%200%22%2F%3E%3C%2Fsvg%3E);
|
|
115
|
+
background-repeat: no-repeat;
|
|
116
|
+
background-position: 0 50%;
|
|
117
|
+
background-size: 1rem;
|
|
118
|
+
|
|
119
|
+
// &::before {
|
|
120
|
+
// transform: unset;
|
|
121
|
+
// // transition: unset;
|
|
122
|
+
// }
|
|
123
|
+
|
|
124
|
+
&:active {
|
|
125
|
+
box-shadow: inset 0 0 0.25rem;
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
|
|
112
129
|
&:hover,
|
|
113
130
|
&:active,
|
|
114
131
|
&.highlighted {
|
|
@@ -4,6 +4,7 @@ export interface HeaderTitleProps {
|
|
|
4
4
|
* Can be an image. Will be placed inside of the `src` attribute.
|
|
5
5
|
*/
|
|
6
6
|
logo?: string;
|
|
7
|
+
logoAlt?: string;
|
|
7
8
|
/**
|
|
8
9
|
* Text next to the logo.
|
|
9
10
|
*/
|
|
@@ -21,9 +22,19 @@ export interface HeaderTitleProps {
|
|
|
21
22
|
* Is the component used on the sidebar?
|
|
22
23
|
*/
|
|
23
24
|
sidebar?: boolean;
|
|
25
|
+
/**
|
|
26
|
+
* By default, MenuItem is a `"a"`.
|
|
27
|
+
* If you want to have it another type, you can pass a component reference with this prop (e.g. `Link`).
|
|
28
|
+
*/
|
|
29
|
+
elementType?: any;
|
|
30
|
+
/**
|
|
31
|
+
* Sets `to` prop, e.g. when you use the `Link` component from React Router.
|
|
32
|
+
*/
|
|
33
|
+
to?: string;
|
|
34
|
+
href?: string;
|
|
24
35
|
}
|
|
25
36
|
/**
|
|
26
37
|
* The title area at the header bar.
|
|
27
38
|
* Depending on its content, the document's title will be set aswell (what will be shown in the browser title bar).
|
|
28
39
|
*/
|
|
29
|
-
export default function HeaderTitle({ logo, appTitle, keepAppTitle, children, className, sidebar }: HeaderTitleProps): JSX.Element;
|
|
40
|
+
export default function HeaderTitle({ logo, logoAlt, appTitle, keepAppTitle, children, className, sidebar, elementType, to, href }: HeaderTitleProps): JSX.Element;
|
|
@@ -121,6 +121,8 @@ export interface MenuItemProps {
|
|
|
121
121
|
onDrop?: (event: React.DragEvent) => void | React.DragEventHandler;
|
|
122
122
|
/**
|
|
123
123
|
* Specifies whether an element is draggable or not.
|
|
124
|
+
*
|
|
125
|
+
* **Important:** To make draggable menu items work in Firefox, the elementType must not be `"button"`. Set it to something else, like `"div"`.
|
|
124
126
|
*/
|
|
125
127
|
draggable?: boolean;
|
|
126
128
|
"data-tooltip"?: string;
|
|
@@ -132,6 +134,7 @@ export interface MenuItemProps {
|
|
|
132
134
|
* Specifies style of an element.
|
|
133
135
|
*/
|
|
134
136
|
style?: React.CSSProperties;
|
|
137
|
+
id?: string;
|
|
135
138
|
}
|
|
136
139
|
/**
|
|
137
140
|
* Link, button or custom component for Sidebar, Actions or ActionMenu
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "blue-react",
|
|
3
|
-
"version": "9.
|
|
3
|
+
"version": "9.5.1",
|
|
4
4
|
"description": "Blue React Components",
|
|
5
5
|
"license": "LGPL-3.0-or-later",
|
|
6
6
|
"main": "index.js",
|
|
@@ -19,7 +19,6 @@
|
|
|
19
19
|
"build-types": "tsc --declaration --emitDeclarationOnly --declarationDir ./dist/types --noEmit false",
|
|
20
20
|
"build": "babel ./src/components --out-dir ./dist/components --extensions \".tsx,.js,.ts\"",
|
|
21
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-css-better": "postcss ./dist/style.scss -o ./dist/style.css",
|
|
23
22
|
"build-neu-css": "node-sass ./dist/neu.scss ./dist/neu.css && npx postcss ./dist/neu.css --use autoprefixer -r && npx postcss ./dist/neu.css --use postcss-minify -o ./dist/neu.min.css",
|
|
24
23
|
"build-release": "npm run build-types && npm run build && npm run build-css && npm run docgen",
|
|
25
24
|
"docgen": "react-docgen ./src/components/ -o ./src/docs/data/docs.json --exclude Utilities.js --extension tsx && node followUpDocs && npm run license-report",
|
|
@@ -34,7 +33,7 @@
|
|
|
34
33
|
},
|
|
35
34
|
"dependencies": {
|
|
36
35
|
"@popperjs/core": "^2.11.5",
|
|
37
|
-
"bootstrap": "~5.3.
|
|
36
|
+
"bootstrap": "~5.3.3",
|
|
38
37
|
"clsx": "^1.1.1"
|
|
39
38
|
},
|
|
40
39
|
"peerDependencies": {
|
|
@@ -62,7 +61,6 @@
|
|
|
62
61
|
"node-sass": "^9.0.0",
|
|
63
62
|
"postcss-cli": "^9.0.1",
|
|
64
63
|
"postcss-minify": "^1.1.0",
|
|
65
|
-
"postcss-scss": "^4.0.9",
|
|
66
64
|
"prettier": "2.4.1",
|
|
67
65
|
"react": "^18.1.0",
|
|
68
66
|
"react-bootstrap-icons": "^1.9.1",
|