revdev-components 0.252.0 → 0.254.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.
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import { LevelGen } from "src/interfaces";
|
|
3
3
|
export interface LevelLetterBadgeProps {
|
|
4
|
-
|
|
4
|
+
levels: LevelGen | LevelGen[] | string;
|
|
5
5
|
className?: string;
|
|
6
6
|
activeCode?: string;
|
|
7
7
|
title?: (param: LevelGen) => string;
|
package/build/index.js
CHANGED
|
@@ -6136,10 +6136,11 @@ var LevelBarBadge = function (_a) {
|
|
|
6136
6136
|
children));
|
|
6137
6137
|
};
|
|
6138
6138
|
|
|
6139
|
-
var s$3 = {"root":"index-module_root__ogwMI","level":"index-module_level__EuETi","level__active":"index-module_level__active__lfzHe"};
|
|
6139
|
+
var s$3 = {"root":"index-module_root__ogwMI","root__hasActive":"index-module_root__hasActive__qvsDL","level":"index-module_level__EuETi","level__active":"index-module_level__active__lfzHe"};
|
|
6140
6140
|
|
|
6141
6141
|
var LevelLetterBadge = function (_a) {
|
|
6142
|
-
var
|
|
6142
|
+
var _b;
|
|
6143
|
+
var value = _a.levels, className = _a.className, activeCode = _a.activeCode, title = _a.title;
|
|
6143
6144
|
var levels = React.useMemo(function () {
|
|
6144
6145
|
if (typeof value === "string") {
|
|
6145
6146
|
return [{ code: value }];
|
|
@@ -6149,7 +6150,7 @@ var LevelLetterBadge = function (_a) {
|
|
|
6149
6150
|
if (levels.length === 0) {
|
|
6150
6151
|
return null;
|
|
6151
6152
|
}
|
|
6152
|
-
return (React.createElement("div", { className: classNames(s$3.root, className) }, levels.map(function (level) {
|
|
6153
|
+
return (React.createElement("div", { className: classNames(s$3.root, className, (_b = {}, _b[s$3.root__hasActive] = !!activeCode, _b)) }, levels.map(function (level) {
|
|
6153
6154
|
var _a;
|
|
6154
6155
|
var _b;
|
|
6155
6156
|
return (React.createElement(AppTooltip, { key: level.code, title: title ? title(level) : "Proficiency language level: ".concat(level.code.toUpperCase()) },
|
package/build/styles.css
CHANGED
|
@@ -40,9 +40,6 @@
|
|
|
40
40
|
--levelBadgeRateColor: #555;
|
|
41
41
|
--levelBarBadgeBarColor: var(--passiveColor);
|
|
42
42
|
--levelBarBadgeBackgroundColor: rgb(15, 23, 42, 5.5%);
|
|
43
|
-
--levelLetterBadgeActiveBackgroundColor: rgb(15, 23, 42, 14%);
|
|
44
|
-
--levelLetterBadgeActiveTextColor: var(--color);
|
|
45
|
-
--levelLetterBadgeActiveBorderColor: color-mix(in srgb, var(--borderColor) 35%, var(--color));
|
|
46
43
|
--rowContentFontSize: 14px;
|
|
47
44
|
--rowContentTitleFontSize: 20px;
|
|
48
45
|
}
|
|
@@ -780,6 +777,9 @@ body {
|
|
|
780
777
|
flex-direction: row;
|
|
781
778
|
gap: 0.3em;
|
|
782
779
|
}
|
|
780
|
+
.index-module_root__hasActive__qvsDL {
|
|
781
|
+
color: var(--passiveColor);
|
|
782
|
+
}
|
|
783
783
|
|
|
784
784
|
.index-module_level__EuETi {
|
|
785
785
|
display: inline-flex;
|
|
@@ -787,11 +787,11 @@ body {
|
|
|
787
787
|
border: 1px solid var(--borderColor);
|
|
788
788
|
border-radius: 0.3em;
|
|
789
789
|
text-transform: uppercase;
|
|
790
|
+
line-height: 1.2em;
|
|
790
791
|
}
|
|
791
792
|
.index-module_level__active__lfzHe {
|
|
792
|
-
|
|
793
|
-
color: var(--
|
|
794
|
-
border-color: var(--levelLetterBadgeActiveBorderColor);
|
|
793
|
+
color: var(--color);
|
|
794
|
+
border-color: var(--color);
|
|
795
795
|
}
|
|
796
796
|
.index-module_label__7pG3Z {
|
|
797
797
|
font-size: 12px;
|