@steroidsjs/bootstrap 2.1.12 → 2.1.15
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.
|
@@ -21,6 +21,7 @@
|
|
|
21
21
|
|
|
22
22
|
cursor: pointer;
|
|
23
23
|
transition: color .1s ease-in;
|
|
24
|
+
|
|
24
25
|
&:hover, &:active, &:focus {
|
|
25
26
|
color: $calendar-primary-color;
|
|
26
27
|
}
|
|
@@ -37,24 +38,27 @@
|
|
|
37
38
|
fill: rgba(0, 0, 0, 0.25);
|
|
38
39
|
transition: fill .1s ease-in;
|
|
39
40
|
}
|
|
40
|
-
|
|
41
|
+
|
|
42
|
+
&_one-arrow.IconView svg {
|
|
41
43
|
width: 8px;
|
|
42
44
|
}
|
|
43
45
|
|
|
44
46
|
&:hover svg {
|
|
45
|
-
fill: rgba(0,0,0
|
|
47
|
+
fill: rgba(0, 0, 0, .7);
|
|
46
48
|
}
|
|
47
49
|
}
|
|
48
50
|
|
|
49
51
|
&__selected-month, &__selected-year {
|
|
50
52
|
font-size: 16px;
|
|
51
53
|
}
|
|
54
|
+
|
|
52
55
|
&__selected-month {
|
|
53
56
|
margin-right: 5px;
|
|
54
57
|
}
|
|
55
58
|
|
|
56
59
|
// Panel changing Month/Year
|
|
57
60
|
|
|
61
|
+
|
|
58
62
|
&__panel {
|
|
59
63
|
z-index: 10;
|
|
60
64
|
position: absolute;
|
|
@@ -63,67 +67,67 @@
|
|
|
63
67
|
right: 0;
|
|
64
68
|
bottom: 50px;
|
|
65
69
|
background-color: $white;
|
|
66
|
-
|
|
70
|
+
|
|
71
|
+
display: grid;
|
|
72
|
+
grid-template-columns: 1fr 1fr 1fr;
|
|
73
|
+
grid-template-rows: 0fr 1fr;
|
|
74
|
+
gap: 0 0;
|
|
75
|
+
grid-template-areas:
|
|
76
|
+
"HeaderMonths HeaderMonths HeaderYears"
|
|
77
|
+
"Months1stCol Months2ndCol YearsCol";
|
|
67
78
|
|
|
68
79
|
&_full-height {
|
|
69
80
|
bottom: 0;
|
|
70
81
|
}
|
|
82
|
+
}
|
|
71
83
|
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
display: grid;
|
|
75
|
-
grid-template-columns: 1fr 1fr 1fr;
|
|
76
|
-
grid-template-rows: 0fr 1fr;
|
|
77
|
-
gap: 0 0;
|
|
78
|
-
grid-template-areas:
|
|
79
|
-
"HeaderMonths HeaderMonths HeaderYears"
|
|
80
|
-
"Months1stCol Months2ndCol YearsCol";
|
|
81
|
-
}
|
|
84
|
+
&__panel-header {
|
|
85
|
+
padding: 5px;
|
|
82
86
|
|
|
83
|
-
|
|
84
|
-
|
|
87
|
+
text-align: center;
|
|
88
|
+
border-bottom: 1px solid $border-color;
|
|
89
|
+
background-color: $calendar-primary-light-color;
|
|
85
90
|
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
91
|
+
&_months {
|
|
92
|
+
grid-area: HeaderMonths;
|
|
93
|
+
border-right: 1px solid $border-color;
|
|
94
|
+
}
|
|
89
95
|
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
border-right: 1px solid $border-color;
|
|
93
|
-
}
|
|
94
|
-
&_years {
|
|
95
|
-
grid-area: HeaderYears;
|
|
96
|
-
}
|
|
96
|
+
&_years {
|
|
97
|
+
grid-area: HeaderYears;
|
|
97
98
|
}
|
|
99
|
+
}
|
|
98
100
|
|
|
99
|
-
|
|
100
|
-
|
|
101
|
+
&__panel-column-months {
|
|
102
|
+
border-right: 1px solid $border-color;
|
|
101
103
|
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
}
|
|
105
|
-
&_second {
|
|
106
|
-
grid-area: Months2ndCol;
|
|
107
|
-
}
|
|
104
|
+
&_first {
|
|
105
|
+
grid-area: Months1stCol;
|
|
108
106
|
}
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
grid-area:
|
|
112
|
-
overflow: auto;
|
|
107
|
+
|
|
108
|
+
&_second {
|
|
109
|
+
grid-area: Months2ndCol;
|
|
113
110
|
}
|
|
111
|
+
}
|
|
114
112
|
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
113
|
+
&__panel-column-years {
|
|
114
|
+
height: 100%;
|
|
115
|
+
grid-area: YearsCol;
|
|
116
|
+
overflow: auto;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
&__panel-cell {
|
|
120
|
+
padding: 5px 15px;
|
|
121
|
+
cursor: pointer;
|
|
122
|
+
|
|
123
|
+
&_selected {
|
|
124
|
+
background-color: $calendar-primary-light-color;
|
|
125
|
+
}
|
|
118
126
|
|
|
119
|
-
|
|
120
|
-
background-color: $calendar-primary-light-color;
|
|
121
|
-
}
|
|
127
|
+
transition: background-color .1s ease-in;
|
|
122
128
|
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
background-color: $calendar-secondary-light-color;
|
|
126
|
-
}
|
|
129
|
+
&:hover {
|
|
130
|
+
background-color: $calendar-secondary-light-color;
|
|
127
131
|
}
|
|
128
132
|
}
|
|
129
133
|
}
|
|
@@ -18,21 +18,34 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
18
18
|
__setModuleDefault(result, mod);
|
|
19
19
|
return result;
|
|
20
20
|
};
|
|
21
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
22
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
23
|
+
};
|
|
21
24
|
exports.__esModule = true;
|
|
25
|
+
var isFunction_1 = __importDefault(require("lodash-es/isFunction"));
|
|
22
26
|
var React = __importStar(require("react"));
|
|
23
27
|
var react_use_1 = require("react-use");
|
|
24
28
|
var hooks_1 = require("@steroidsjs/core/hooks");
|
|
25
29
|
require("./DropDownView.scss");
|
|
30
|
+
var react_1 = require("react");
|
|
26
31
|
function DropDownView(props) {
|
|
27
32
|
var _a;
|
|
28
33
|
var bem = hooks_1.useBem('DropDownView');
|
|
34
|
+
var ui = hooks_1.useComponents().ui;
|
|
29
35
|
react_use_1.useMount(function () {
|
|
30
36
|
props.calculatePosition(props.forwardedRef.current.getBoundingClientRect());
|
|
31
37
|
});
|
|
38
|
+
var contentProps = react_1.useMemo(function () { return ({
|
|
39
|
+
onClose: props.onClose
|
|
40
|
+
}); }, [props.onClose]);
|
|
41
|
+
var content = props.content();
|
|
42
|
+
if (isFunction_1["default"](content)) {
|
|
43
|
+
content = ui.renderView(content, contentProps);
|
|
44
|
+
}
|
|
32
45
|
return (React.createElement("div", { ref: props.forwardedRef, className: bem(bem.block((_a = {
|
|
33
46
|
show: props.isComponentVisible
|
|
34
47
|
},
|
|
35
48
|
_a["position-" + props.position] = !!props.position,
|
|
36
|
-
_a)), props.className), style: props.style },
|
|
49
|
+
_a)), props.className), style: props.style }, content));
|
|
37
50
|
}
|
|
38
51
|
exports["default"] = DropDownView;
|
|
@@ -27,7 +27,7 @@ var hooks_1 = require("@steroidsjs/core/hooks");
|
|
|
27
27
|
var Icon_1 = __importDefault(require("@steroidsjs/core/ui/icon/Icon"));
|
|
28
28
|
function FileFieldItemView(props) {
|
|
29
29
|
var bem = hooks_1.useBem('FileFieldItemView');
|
|
30
|
-
return (React.createElement("div", { className: bem(bem.block(), 'card
|
|
30
|
+
return (React.createElement("div", { className: bem(bem.block(), 'card mb-1 mr-1', props.error && 'border-danger') },
|
|
31
31
|
props.image
|
|
32
32
|
? (React.createElement("img", { src: props.image.url, className: 'card-img-top', width: props.image.width, height: props.image.height, alt: props.title }))
|
|
33
33
|
: (React.createElement(Icon_1["default"], { className: bem.element('blank-img'), name: props.imagesOnly ? 'file-image' : 'file' })),
|
|
@@ -42,7 +42,7 @@ function FileFieldView(props) {
|
|
|
42
42
|
var ButtonComponent = props.buttonComponent || Button_1["default"];
|
|
43
43
|
var FileItemView = props.itemView;
|
|
44
44
|
return (React.createElement("div", { className: bem.block() },
|
|
45
|
-
React.createElement("div", { className: bem(bem.element('files')
|
|
45
|
+
React.createElement("div", { className: bem(bem.element('files')) }, props.items.map(function (item) { return (React.createElement(FileItemView, __assign({ key: item.uid }, item, props.itemProps))); })),
|
|
46
46
|
React.createElement("div", { className: bem.element('button') },
|
|
47
47
|
React.createElement(ButtonComponent, __assign({}, props.buttonProps, { layout: false, label: null }),
|
|
48
48
|
React.createElement(Icon_1["default"], { className: bem.element('button-icon'), name: props.imagesOnly ? 'file-image' : 'upload' }),
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@steroidsjs/bootstrap",
|
|
3
|
-
"version": "2.1.
|
|
3
|
+
"version": "2.1.15",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"author": "Vladimir Kozhin <hello@kozhindev.com>",
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
"dependencies": {
|
|
20
20
|
"@ckeditor/ckeditor5-react": "^3.0.2",
|
|
21
21
|
"@steroidsjs/ckeditor5": "^27.0.2-rc.2",
|
|
22
|
-
"@steroidsjs/core": "^2.2.
|
|
22
|
+
"@steroidsjs/core": "^2.2.44",
|
|
23
23
|
"bootstrap": "^4.5.2",
|
|
24
24
|
"lodash": "^4.17.20",
|
|
25
25
|
"lodash-es": "^4.17.20",
|