math-main-components 0.0.153 → 0.0.155
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.
@@ -1,3 +1,8 @@
|
|
1
|
-
import React from 'react';
|
2
|
-
|
3
|
-
|
1
|
+
import React, { MouseEvent } from 'react';
|
2
|
+
export declare function SvgIcon({ id, iconName, size, onClick }: {
|
3
|
+
id?: string;
|
4
|
+
iconName?: string;
|
5
|
+
size?: string;
|
6
|
+
fill?: string;
|
7
|
+
onClick?: (event: MouseEvent<HTMLSpanElement>) => void;
|
8
|
+
}): React.JSX.Element;
|
package/dist/index.cjs.js
CHANGED
@@ -8,9 +8,8 @@ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'defau
|
|
8
8
|
|
9
9
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
10
10
|
|
11
|
-
function SvgIcon({ iconName, size = "24px",
|
12
|
-
return (React__default["default"].createElement(
|
13
|
-
React__default["default"].createElement("span", { onClick: onClick, className: `material-symbols-outlined ${className}`, style: { fontSize: size } }, iconName)));
|
11
|
+
function SvgIcon({ id, iconName, size = "24px", onClick }) {
|
12
|
+
return (React__default["default"].createElement("span", { onClick: onClick, className: "material-symbols-outlined", id: id, style: { fontSize: size } }, iconName));
|
14
13
|
}
|
15
14
|
|
16
15
|
function styleInject(css, ref) {
|
@@ -458,7 +457,7 @@ function ProgressBar({ length, progress }) {
|
|
458
457
|
React__default["default"].createElement("div", { className: styles$a.progress, style: { width: `${progress / length * 100}%` } })))));
|
459
458
|
}
|
460
459
|
|
461
|
-
var css_248z$9 = ".styles-module_container__Grkzw {\n display: flex;\n flex-direction: column;\n gap: 12px;\n color: var(--foreground-3);\n margin-bottom: 20px;\n position: relative;\n}\n.styles-module_container__Grkzw [type=radio] {\n position: relative;\n left: 15px;\n top: -4px;\n z-index: 0;\n appearance: none;\n -webkit-appearance: none;\n cursor: pointer;\n margin-left: -3.5px;\n}\n.styles-module_container__Grkzw [type=radio] + label {\n position: absolute;\n cursor: pointer;\n}\n.styles-module_container__Grkzw [type=radio] + label::before {\n width: 15px;\n height: 15px;\n border-radius: 20px;\n border: 2px solid var(--border-2);\n display: block;\n content: \"\";\n float: left;\n margin-right: 8px;\n z-index: 5;\n position: relative;\n transition: 0.2s ease-in-out;\n}\n.styles-module_container__Grkzw .styles-module_option__nijjM {\n position: relative;\n}\n.styles-module_container__Grkzw [type=radio] ~ span {\n position: absolute;\n opacity: 1;\n color: var(--background-1);\n z-index: 100;\n user-select: none;\n pointer-events: none;\n -webkit-user-select: none;\n font-weight: 500;\n bottom: -1.5px;\n left: -1px;\n}\n.styles-module_container__Grkzw [type=radio]:checked ~ span {\n color: var(--
|
460
|
+
var css_248z$9 = ".styles-module_container__Grkzw {\n display: flex;\n flex-direction: column;\n gap: 12px;\n color: var(--foreground-3);\n margin-bottom: 20px;\n position: relative;\n}\n.styles-module_container__Grkzw [type=radio] {\n position: relative;\n left: 15px;\n top: -4px;\n z-index: 0;\n appearance: none;\n -webkit-appearance: none;\n cursor: pointer;\n margin-left: -3.5px;\n}\n.styles-module_container__Grkzw [type=radio] + label {\n position: absolute;\n cursor: pointer;\n}\n.styles-module_container__Grkzw [type=radio] + label::before {\n width: 15px;\n height: 15px;\n border-radius: 20px;\n border: 2px solid var(--border-2);\n display: block;\n content: \"\";\n float: left;\n margin-right: 8px;\n z-index: 5;\n position: relative;\n transition: 0.2s ease-in-out;\n}\n.styles-module_container__Grkzw .styles-module_option__nijjM {\n position: relative;\n}\n.styles-module_container__Grkzw [type=radio] ~ span {\n position: absolute;\n opacity: 1;\n color: var(--background-1);\n z-index: 100;\n user-select: none;\n pointer-events: none;\n -webkit-user-select: none;\n font-weight: 500;\n bottom: -1.5px;\n left: -1px;\n}\n.styles-module_container__Grkzw [type=radio]:checked ~ span {\n color: var(--background-1);\n}\n.styles-module_container__Grkzw [type=radio]:checked + label::before {\n background-color: var(--primary-1);\n border-color: var(--primary-1);\n}\n.styles-module_container__Grkzw [type=radio]:hover:not(:checked) + label::before {\n background-color: var(--background-4);\n border-color: var(--background-4);\n}";
|
462
461
|
var styles$9 = {"container":"styles-module_container__Grkzw","option":"styles-module_option__nijjM"};
|
463
462
|
styleInject(css_248z$9);
|
464
463
|
|
@@ -483,7 +482,7 @@ function RadioButtons({ options, group, selected, onClick, width = "100%" }) {
|
|
483
482
|
:
|
484
483
|
React__default["default"].createElement("input", { type: "radio", id: option.name, name: group, value: option.name, onInput: onUpdateSelected }),
|
485
484
|
React__default["default"].createElement("label", { htmlFor: option.name }, option.text),
|
486
|
-
React__default["default"].createElement(SvgIcon, { iconName: "done", size: "20px"
|
485
|
+
React__default["default"].createElement(SvgIcon, { iconName: "done", size: "20px" })))));
|
487
486
|
}
|
488
487
|
|
489
488
|
var css_248z$8 = ".styles-module_container__RhsQe {\n margin-right: 8px;\n}\n.styles-module_container__RhsQe .styles-module_button__HuX-0 {\n background: none;\n padding: none;\n border: none;\n width: 40px;\n height: 40px;\n transition: 0.2s;\n cursor: pointer;\n display: flex;\n justify-content: center;\n align-items: center;\n border-radius: 20px;\n}\n.styles-module_container__RhsQe .styles-module_button__HuX-0 span {\n color: var(--foreground-1);\n}\n.styles-module_container__RhsQe .styles-module_button__HuX-0:hover {\n background: var(--background-1);\n}\n.styles-module_container__RhsQe.styles-module_middle__xg7RF .styles-module_button__HuX-0 {\n flex-direction: row;\n gap: 5px;\n}\n.styles-module_container__RhsQe.styles-module_middle__xg7RF .styles-module_button__HuX-0:hover {\n background: none;\n}";
|
package/dist/index.esm.js
CHANGED
@@ -1,8 +1,7 @@
|
|
1
1
|
import React, { useState, useCallback, useRef, createRef, useEffect } from 'react';
|
2
2
|
|
3
|
-
function SvgIcon({ iconName, size = "24px",
|
4
|
-
return (React.createElement(
|
5
|
-
React.createElement("span", { onClick: onClick, className: `material-symbols-outlined ${className}`, style: { fontSize: size } }, iconName)));
|
3
|
+
function SvgIcon({ id, iconName, size = "24px", onClick }) {
|
4
|
+
return (React.createElement("span", { onClick: onClick, className: "material-symbols-outlined", id: id, style: { fontSize: size } }, iconName));
|
6
5
|
}
|
7
6
|
|
8
7
|
function styleInject(css, ref) {
|
@@ -450,7 +449,7 @@ function ProgressBar({ length, progress }) {
|
|
450
449
|
React.createElement("div", { className: styles$a.progress, style: { width: `${progress / length * 100}%` } })))));
|
451
450
|
}
|
452
451
|
|
453
|
-
var css_248z$9 = ".styles-module_container__Grkzw {\n display: flex;\n flex-direction: column;\n gap: 12px;\n color: var(--foreground-3);\n margin-bottom: 20px;\n position: relative;\n}\n.styles-module_container__Grkzw [type=radio] {\n position: relative;\n left: 15px;\n top: -4px;\n z-index: 0;\n appearance: none;\n -webkit-appearance: none;\n cursor: pointer;\n margin-left: -3.5px;\n}\n.styles-module_container__Grkzw [type=radio] + label {\n position: absolute;\n cursor: pointer;\n}\n.styles-module_container__Grkzw [type=radio] + label::before {\n width: 15px;\n height: 15px;\n border-radius: 20px;\n border: 2px solid var(--border-2);\n display: block;\n content: \"\";\n float: left;\n margin-right: 8px;\n z-index: 5;\n position: relative;\n transition: 0.2s ease-in-out;\n}\n.styles-module_container__Grkzw .styles-module_option__nijjM {\n position: relative;\n}\n.styles-module_container__Grkzw [type=radio] ~ span {\n position: absolute;\n opacity: 1;\n color: var(--background-1);\n z-index: 100;\n user-select: none;\n pointer-events: none;\n -webkit-user-select: none;\n font-weight: 500;\n bottom: -1.5px;\n left: -1px;\n}\n.styles-module_container__Grkzw [type=radio]:checked ~ span {\n color: var(--
|
452
|
+
var css_248z$9 = ".styles-module_container__Grkzw {\n display: flex;\n flex-direction: column;\n gap: 12px;\n color: var(--foreground-3);\n margin-bottom: 20px;\n position: relative;\n}\n.styles-module_container__Grkzw [type=radio] {\n position: relative;\n left: 15px;\n top: -4px;\n z-index: 0;\n appearance: none;\n -webkit-appearance: none;\n cursor: pointer;\n margin-left: -3.5px;\n}\n.styles-module_container__Grkzw [type=radio] + label {\n position: absolute;\n cursor: pointer;\n}\n.styles-module_container__Grkzw [type=radio] + label::before {\n width: 15px;\n height: 15px;\n border-radius: 20px;\n border: 2px solid var(--border-2);\n display: block;\n content: \"\";\n float: left;\n margin-right: 8px;\n z-index: 5;\n position: relative;\n transition: 0.2s ease-in-out;\n}\n.styles-module_container__Grkzw .styles-module_option__nijjM {\n position: relative;\n}\n.styles-module_container__Grkzw [type=radio] ~ span {\n position: absolute;\n opacity: 1;\n color: var(--background-1);\n z-index: 100;\n user-select: none;\n pointer-events: none;\n -webkit-user-select: none;\n font-weight: 500;\n bottom: -1.5px;\n left: -1px;\n}\n.styles-module_container__Grkzw [type=radio]:checked ~ span {\n color: var(--background-1);\n}\n.styles-module_container__Grkzw [type=radio]:checked + label::before {\n background-color: var(--primary-1);\n border-color: var(--primary-1);\n}\n.styles-module_container__Grkzw [type=radio]:hover:not(:checked) + label::before {\n background-color: var(--background-4);\n border-color: var(--background-4);\n}";
|
454
453
|
var styles$9 = {"container":"styles-module_container__Grkzw","option":"styles-module_option__nijjM"};
|
455
454
|
styleInject(css_248z$9);
|
456
455
|
|
@@ -475,7 +474,7 @@ function RadioButtons({ options, group, selected, onClick, width = "100%" }) {
|
|
475
474
|
:
|
476
475
|
React.createElement("input", { type: "radio", id: option.name, name: group, value: option.name, onInput: onUpdateSelected }),
|
477
476
|
React.createElement("label", { htmlFor: option.name }, option.text),
|
478
|
-
React.createElement(SvgIcon, { iconName: "done", size: "20px"
|
477
|
+
React.createElement(SvgIcon, { iconName: "done", size: "20px" })))));
|
479
478
|
}
|
480
479
|
|
481
480
|
var css_248z$8 = ".styles-module_container__RhsQe {\n margin-right: 8px;\n}\n.styles-module_container__RhsQe .styles-module_button__HuX-0 {\n background: none;\n padding: none;\n border: none;\n width: 40px;\n height: 40px;\n transition: 0.2s;\n cursor: pointer;\n display: flex;\n justify-content: center;\n align-items: center;\n border-radius: 20px;\n}\n.styles-module_container__RhsQe .styles-module_button__HuX-0 span {\n color: var(--foreground-1);\n}\n.styles-module_container__RhsQe .styles-module_button__HuX-0:hover {\n background: var(--background-1);\n}\n.styles-module_container__RhsQe.styles-module_middle__xg7RF .styles-module_button__HuX-0 {\n flex-direction: row;\n gap: 5px;\n}\n.styles-module_container__RhsQe.styles-module_middle__xg7RF .styles-module_button__HuX-0:hover {\n background: none;\n}";
|