tamga-ui 0.5.0 → 0.5.2
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/CHANGELOG.md +62 -0
- package/README.md +0 -4
- package/dist/components/a11y.d.ts.map +1 -1
- package/dist/components/a11y.js +9 -3
- package/dist/components/checkbox.js +1 -1
- package/dist/fonts.css +1 -1
- package/dist/kit.css +11 -23
- package/dist/lib/palette.d.ts.map +1 -1
- package/dist/lib/palette.js +13 -11
- package/dist/styles.css +1 -1
- package/dist/theme.css +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,68 @@ Versions follow [semver](https://semver.org/). Through `0.x`, breaking changes m
|
|
|
5
5
|
|
|
6
6
|
> 🇹🇷 Türkçe için [tamga.org.tr/tr](https://tamga.org.tr/tr).
|
|
7
7
|
|
|
8
|
+
## 0.5.2
|
|
9
|
+
|
|
10
|
+
> A light palette takes the brand's hue, and two things a pointer could feel: a checkbox
|
|
11
|
+
> that flickered under hover and a two-line label that centred itself.
|
|
12
|
+
|
|
13
|
+
### Fixed
|
|
14
|
+
|
|
15
|
+
- **`Checkbox` no longer centres a two-line label.** It renders a `<button>`, and a browser centres
|
|
16
|
+
button text; every other choice surface in the kit already neutralises that (`RadioGroup`'s list
|
|
17
|
+
look, `.tamga-choice-card`), this one did not. A one-word label never showed it; a label with a
|
|
18
|
+
description under it did.
|
|
19
|
+
|
|
20
|
+
## Unreleased
|
|
21
|
+
|
|
22
|
+
### Changed
|
|
23
|
+
|
|
24
|
+
- **A light palette now carries the brand's hue.** `makePalette` fixed every light surface at hue
|
|
25
|
+
90 — `page`, `shell`, `rail`, `hover`, `sunk`, `line`, `div` were the same warm paper whatever the
|
|
26
|
+
brand, while the dark half breathed in the brand's hue. Only the HUE moves: the lightness steps
|
|
27
|
+
and the chroma ceiling are untouched, so the contrast that makes a panel comfortable to read is
|
|
28
|
+
the same number it was (measured: ink over page stays above 15). The warm-brand guard still holds
|
|
29
|
+
a red or orange brand at the paper hue, because a surface pulled toward those reads as dirty
|
|
30
|
+
rather than tinted.
|
|
31
|
+
|
|
32
|
+
### Fixed
|
|
33
|
+
|
|
34
|
+
- **A hovered checkbox no longer flickers.** The box lifts a pixel on hover, and the hover target
|
|
35
|
+
was the box itself: a pointer resting on its lower or right edge lost the box as it moved, the
|
|
36
|
+
hover ended, the box came back, the hover started again — a loop that does not stop, because the
|
|
37
|
+
pointer never moved. Hover now belongs to the wrapping control, which does not move. The label
|
|
38
|
+
lights the box too, which is where a checkbox's hit area always was.
|
|
39
|
+
|
|
40
|
+
## 0.5.1
|
|
41
|
+
|
|
42
|
+
> Three corrections the 0.5.0 port left behind: a menu that stole the page's scroll, and the
|
|
43
|
+
> rail's hover, lift and press.
|
|
44
|
+
|
|
45
|
+
### Changed
|
|
46
|
+
|
|
47
|
+
- **The rail's hover is a wash again, and the current row lifts.** Hovering a row had it grow a
|
|
48
|
+
border and a base, turning every row into its own button: a rail is a list of eight, and eight
|
|
49
|
+
controls under the pointer is not navigation. Hover is now only the wash the kit already had a
|
|
50
|
+
token for (`--color-nav-hover-bg`), and the current row — which never takes that wash — lifts by
|
|
51
|
+
a pixel over its 3px base, so "you are here" is the one thing standing up. Law 2 is untouched:
|
|
52
|
+
it binds the FILL to an action, not the height, and the current row still speaks with an
|
|
53
|
+
outline. The pressed row travels 2px, which is the 3px of its base measured from where it
|
|
54
|
+
actually rests.
|
|
55
|
+
|
|
56
|
+
- **A pressed segment no longer sinks below its own ground.** The selected tab rests a pixel up so
|
|
57
|
+
its shadow has room, which puts its ground at 1px; it was travelling 2px. The physics gate could
|
|
58
|
+
not see this because it measured the ARRIVAL, not the travel, and every family with a shadow
|
|
59
|
+
used to rest flat — that is fixed too, and the gate found this the moment it could.
|
|
60
|
+
|
|
61
|
+
### Fixed
|
|
62
|
+
|
|
63
|
+
- **A menu that starts open no longer steals the focus.** `DropdownMenu` with `defaultOpen`
|
|
64
|
+
focused its first option on mount, and the browser scrolls whatever it focuses into view: a page
|
|
65
|
+
carrying such a menu opened thousands of pixels down, past its own heading. The rule is no
|
|
66
|
+
longer "is it open" but "was it just opened" — the focus belongs to whoever performed the
|
|
67
|
+
opening. A menu the visitor opens still focuses its first option, so the arrow keys have
|
|
68
|
+
somewhere to start. Covered by a test.
|
|
69
|
+
|
|
8
70
|
## 0.5.0
|
|
9
71
|
|
|
10
72
|
> The Soft Neo Brutalism port: every component, every token and the physics behind them. The
|
package/README.md
CHANGED
|
@@ -26,10 +26,6 @@ Docs: **[tamga.org.tr](https://tamga.org.tr)** · Changelog: [CHANGELOG.md](./CH
|
|
|
26
26
|
npm install tamga-ui
|
|
27
27
|
```
|
|
28
28
|
|
|
29
|
-
> **If a machine is reading this:** the package page (`npmjs.com/...`) returns **403** to
|
|
30
|
-
> non-browser requests. That is npm's bot protection, nothing to do with this package. For
|
|
31
|
-
> versions and metadata use the registry: `https://registry.npmjs.org/tamga-ui` (200, plain JSON).
|
|
32
|
-
|
|
33
29
|
### Local development
|
|
34
30
|
|
|
35
31
|
To link the kit into a consuming project without publishing, while changing the kit itself:
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"a11y.d.ts","sourceRoot":"","sources":["../../src/components/a11y.ts"],"names":[],"mappings":"AAkCA;;;;;;GAMG;AACH,wBAAgB,YAAY,CAAC,CAAC,SAAS,WAAW,EAAE,IAAI,EAAE,OAAO,uCA0DhE;AAED;;;;;;GAMG;AACH,wBAAgB,WAAW,CAAC,EAC1B,IAAI,EACJ,YAAY,EACZ,OAAO,GACR,EAAE;IACD,IAAI,EAAE,OAAO,CAAC;IACd,YAAY,EAAE,KAAK,CAAC,SAAS,CAAC,WAAW,GAAG,IAAI,CAAC,CAAC;IAClD,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB,
|
|
1
|
+
{"version":3,"file":"a11y.d.ts","sourceRoot":"","sources":["../../src/components/a11y.ts"],"names":[],"mappings":"AAkCA;;;;;;GAMG;AACH,wBAAgB,YAAY,CAAC,CAAC,SAAS,WAAW,EAAE,IAAI,EAAE,OAAO,uCA0DhE;AAED;;;;;;GAMG;AACH,wBAAgB,WAAW,CAAC,EAC1B,IAAI,EACJ,YAAY,EACZ,OAAO,GACR,EAAE;IACD,IAAI,EAAE,OAAO,CAAC;IACd,YAAY,EAAE,KAAK,CAAC,SAAS,CAAC,WAAW,GAAG,IAAI,CAAC,CAAC;IAClD,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB,QA0DA"}
|
package/dist/components/a11y.js
CHANGED
|
@@ -98,16 +98,22 @@ export function useFocusTrap(open) {
|
|
|
98
98
|
* without the hook needing to know what a separator is.
|
|
99
99
|
*/
|
|
100
100
|
export function useListKeys({ open, containerRef, onClose, }) {
|
|
101
|
+
/* Ölçüt "açık mı" değil, "AÇILDI MI": `defaultOpen` ile açık doğan bir menüde
|
|
102
|
+
ilk seçenek odağı alırsa tarayıcı sayfayı ona kaydırıyor.
|
|
103
|
+
Gerekçe: docs/gerekce/07-katman-ve-diyalog.md */
|
|
104
|
+
const acikDogdu = useRef(open);
|
|
101
105
|
useEffect(() => {
|
|
102
|
-
if (!open)
|
|
106
|
+
if (!open) {
|
|
107
|
+
acikDogdu.current = false;
|
|
103
108
|
return;
|
|
109
|
+
}
|
|
104
110
|
const root = containerRef.current;
|
|
105
111
|
if (!root)
|
|
106
112
|
return;
|
|
107
113
|
const items = () => Array.from(root.querySelectorAll("[data-tamga-option]:not([disabled])"));
|
|
108
114
|
/* focus the first option on open, so the arrows have somewhere to start */
|
|
109
|
-
|
|
110
|
-
|
|
115
|
+
if (!acikDogdu.current)
|
|
116
|
+
items()[0]?.focus();
|
|
111
117
|
const onKey = (e) => {
|
|
112
118
|
const list = items();
|
|
113
119
|
if (list.length === 0)
|
|
@@ -12,5 +12,5 @@ import { Check, Minus } from "./icons.js";
|
|
|
12
12
|
* offsetini taşır, böylece kontrol ailesinin bir üyesi gibi okunur.
|
|
13
13
|
* ---------------------------------------------------------------- */
|
|
14
14
|
export function Checkbox({ label, checked, indeterminate = false, onChange, disabled = false, className, compact = false, ...rest }) {
|
|
15
|
-
return (_jsxs("button", { ...dataProps(rest), type: "button", role: "checkbox", "aria-checked": indeterminate ? "mixed" : checked, "aria-disabled": disabled || undefined, disabled: disabled, onClick: () => !disabled && onChange?.(!checked), className: cn("flex items-center gap-2 text-body", disabled && "text-ink-faint", className), children: [_jsx("span", { className: cn("tamga-check", compact && "tamga-check-sm"), "data-checked": (checked || indeterminate) && !disabled, "data-off": disabled || undefined, children: indeterminate ? (_jsx(Icon, { icon: Minus, size: "xs", weight: "bold" })) : checked ? (_jsx(Icon, { icon: Check, size: "xs", weight: "bold" })) : null }), label] }));
|
|
15
|
+
return (_jsxs("button", { ...dataProps(rest), type: "button", role: "checkbox", "aria-checked": indeterminate ? "mixed" : checked, "aria-disabled": disabled || undefined, disabled: disabled, onClick: () => !disabled && onChange?.(!checked), className: cn("flex items-center gap-2 text-left text-body", disabled && "text-ink-faint", className), children: [_jsx("span", { className: cn("tamga-check", compact && "tamga-check-sm"), "data-checked": (checked || indeterminate) && !disabled, "data-off": disabled || undefined, children: indeterminate ? (_jsx(Icon, { icon: Minus, size: "xs", weight: "bold" })) : checked ? (_jsx(Icon, { icon: Check, size: "xs", weight: "bold" })) : null }), label] }));
|
|
16
16
|
}
|
package/dist/fonts.css
CHANGED
package/dist/kit.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! tamga-ui 0.5.
|
|
1
|
+
/*! tamga-ui 0.5.2 · MIT · https://tamga.org.tr */
|
|
2
2
|
:root {
|
|
3
3
|
|
|
4
4
|
--overlay-gap: 8px;
|
|
@@ -433,38 +433,31 @@
|
|
|
433
433
|
padding-inline: 10px;
|
|
434
434
|
}
|
|
435
435
|
|
|
436
|
-
.tamga-rail-link:hover {
|
|
436
|
+
.tamga-rail-link:hover:not([data-active="true"]) {
|
|
437
437
|
color: var(--color-nav-hover);
|
|
438
|
-
background: var(--color-
|
|
439
|
-
border-color: var(--color-edge-strong);
|
|
440
|
-
transform: translate(-1px, -1px);
|
|
441
|
-
box-shadow: 4px 4px 0 var(--color-edge-strong);
|
|
438
|
+
background: var(--color-nav-hover-bg);
|
|
442
439
|
}
|
|
443
440
|
|
|
444
441
|
.tamga-rail-link[data-active="true"] {
|
|
445
442
|
background: var(--color-shell);
|
|
446
443
|
border-color: var(--color-edge-strong);
|
|
444
|
+
transform: translate(-1px, -1px);
|
|
447
445
|
box-shadow: 3px 3px 0 var(--color-edge-strong);
|
|
448
446
|
}
|
|
449
447
|
|
|
450
448
|
.tamga-rail-link[data-active="true"] svg {
|
|
451
449
|
color: var(--color-accent);
|
|
452
450
|
}
|
|
453
|
-
|
|
454
|
-
background: var(--color-shell);
|
|
455
|
-
border-color: var(--color-edge-strong);
|
|
456
|
-
transform: translate(-1px, -1px);
|
|
457
|
-
box-shadow: 4px 4px 0 var(--color-edge-strong);
|
|
458
|
-
}
|
|
451
|
+
|
|
459
452
|
.tamga-rail-link[data-active="true"]:active {
|
|
460
|
-
transform: translate(
|
|
453
|
+
transform: translate(2px, 2px);
|
|
461
454
|
box-shadow: 0 0 0 var(--color-edge-strong);
|
|
462
455
|
}
|
|
463
456
|
|
|
464
457
|
.tamga-btn:not(:disabled):active,
|
|
465
458
|
.tamga-icon-btn:not(:disabled):active,
|
|
466
459
|
.tamga-mini-btn:not(:disabled):active,
|
|
467
|
-
|
|
460
|
+
|
|
468
461
|
.tamga-art-tile:active,
|
|
469
462
|
.tamga-art-route:active {
|
|
470
463
|
transition-duration: 0s;
|
|
@@ -2144,8 +2137,9 @@
|
|
|
2144
2137
|
transform: translate(-1px, -1px);
|
|
2145
2138
|
box-shadow: 3px 3px 0 var(--color-edge);
|
|
2146
2139
|
}
|
|
2140
|
+
|
|
2147
2141
|
.tamga-segment > button[data-active="true"]:active {
|
|
2148
|
-
transform: translate(
|
|
2142
|
+
transform: translate(1px, 1px);
|
|
2149
2143
|
box-shadow: 0 0 0 var(--color-edge);
|
|
2150
2144
|
}
|
|
2151
2145
|
|
|
@@ -2361,7 +2355,6 @@
|
|
|
2361
2355
|
border-radius: var(--radius-chip);
|
|
2362
2356
|
box-shadow: none;
|
|
2363
2357
|
}
|
|
2364
|
-
.tamga-check-sm:hover,
|
|
2365
2358
|
.tamga-check-sm[data-checked="true"] {
|
|
2366
2359
|
transform: none;
|
|
2367
2360
|
box-shadow: none;
|
|
@@ -2381,13 +2374,8 @@
|
|
|
2381
2374
|
cursor: default;
|
|
2382
2375
|
}
|
|
2383
2376
|
|
|
2384
|
-
|
|
2385
|
-
|
|
2386
|
-
transform: none;
|
|
2387
|
-
box-shadow: none;
|
|
2388
|
-
}
|
|
2389
|
-
|
|
2390
|
-
.tamga-check:hover, .tamga-radio:hover {
|
|
2377
|
+
:where(button, label):hover
|
|
2378
|
+
:is(.tamga-check, .tamga-radio):not([data-off]):not(.tamga-check-sm) {
|
|
2391
2379
|
border-color: var(--color-accent-line);
|
|
2392
2380
|
transform: translate(-1px, -1px);
|
|
2393
2381
|
box-shadow: 3px 3px 0 var(--color-accent-line);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"palette.d.ts","sourceRoot":"","sources":["../../src/lib/palette.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,EAAE,KAAK,EAA0B,QAAQ,EAAc,MAAM,YAAY,CAAC;AAEpG;;;;;;;;GAQG;AAEH,qFAAqF;AACrF,MAAM,MAAM,OAAO,GAAG;IACpB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,MAAM,CAAC;IAClB,IAAI,EAAE,MAAM,CAAC;IACb,8EAA8E;IAC9E,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,MAAM,CAAC;IACb,0EAA0E;IAC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D;AAED,OAAO,EAAE,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAC"}
|
package/dist/lib/palette.js
CHANGED
|
@@ -14,13 +14,13 @@ import { lightness, deltaL, isHex, hexToOklch, oklchToHex, contrast } from "./co
|
|
|
14
14
|
const REFERANS_MARKA = { l: 0.49, c: 0.2158, h: 264.4 };
|
|
15
15
|
const BASAMAK = {
|
|
16
16
|
light: {
|
|
17
|
-
page: { l: 0.961, c: 0.0083, k: "
|
|
18
|
-
shell: { l: 0.997, c: 0.0041, k: "
|
|
19
|
-
rail: { l: 0.925, c: 0.0112, k: "
|
|
20
|
-
hover: { l: 0.970, c: 0.0082, k: "
|
|
21
|
-
sunk: { l: 0.898, c: 0.0142, k: "
|
|
22
|
-
line: { l: 0.861, c: 0.0156, k: "
|
|
23
|
-
div: { l: 0.904, c: 0.0129, k: "
|
|
17
|
+
page: { l: 0.961, c: 0.0083, k: "kisitli" },
|
|
18
|
+
shell: { l: 0.997, c: 0.0041, k: "kisitli" },
|
|
19
|
+
rail: { l: 0.925, c: 0.0112, k: "kisitli" },
|
|
20
|
+
hover: { l: 0.970, c: 0.0082, k: "kisitli" },
|
|
21
|
+
sunk: { l: 0.898, c: 0.0142, k: "kisitli" },
|
|
22
|
+
line: { l: 0.861, c: 0.0156, k: "kisitli" },
|
|
23
|
+
div: { l: 0.904, c: 0.0129, k: "kisitli" },
|
|
24
24
|
edge: { l: 0.834, c: 0.0154, k: "kisitli" },
|
|
25
25
|
edgeHover: { l: 0.677, c: 0.0340, k: "kisitli" },
|
|
26
26
|
edgeStrong: { l: 0.241, c: 0.0635, k: "tam" },
|
|
@@ -30,7 +30,7 @@ const BASAMAK = {
|
|
|
30
30
|
inkFaint: { l: 0.460, c: 0.0476, k: "kisitli" },
|
|
31
31
|
navIdle: { l: 0.241, c: 0.0635, k: "tam" },
|
|
32
32
|
navHover: { l: 0.241, c: 0.0635, k: "tam" },
|
|
33
|
-
navHoverBg: { l: 0.997, c: 0.0041, k: "
|
|
33
|
+
navHoverBg: { l: 0.997, c: 0.0041, k: "kisitli" },
|
|
34
34
|
},
|
|
35
35
|
dark: {
|
|
36
36
|
page: { l: 0.218, c: 0.0385, k: "kisitli" },
|
|
@@ -60,11 +60,13 @@ const BASAMAK = {
|
|
|
60
60
|
navHoverBg: { l: 0.257, c: 0.0473, k: "kisitli" },
|
|
61
61
|
},
|
|
62
62
|
};
|
|
63
|
-
/**
|
|
63
|
+
/** Sıcak markada kâğıdın kaçtığı ton. */
|
|
64
64
|
const KAGIT_TONU = 78;
|
|
65
|
+
/* AÇIK YÜZEYLER DE MARKADAN TON ALIYOR. Kâğıtlar `h: 90`da sabitti: seçilen renk ne olursa
|
|
66
|
+
olsun ray, zemin ve kartlar aynı sıcak griydi, oysa koyu tema markanın tonunda nefes
|
|
67
|
+
alıyordu. Değişen yalnız TON · parlaklık ve doyum tavanı aynı kaldığı için kontrast ve
|
|
68
|
+
göz konforu yerinde duruyor (ölçüldü: mürekkep/zemin 15.5+). */
|
|
65
69
|
function notrUret(b, marka, koyu) {
|
|
66
|
-
if (b.k === "sabit")
|
|
67
|
-
return oklchToHex({ l: b.l, c: b.c, h: 90 });
|
|
68
70
|
const oran = Math.max(0.12, Math.min(1.4, marka.c / REFERANS_MARKA.c));
|
|
69
71
|
const tavan = koyu ? 0.02 : 0.022;
|
|
70
72
|
let c = b.k === "tam" ? b.c * oran : Math.min(b.c * oran, tavan);
|
package/dist/styles.css
CHANGED
package/dist/theme.css
CHANGED