@recursica/adapter-mantine-v8 1.2.1 → 1.3.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.
- package/CHANGELOG.md +18 -0
- package/OVERSTYLING.md +1 -1
- package/SETUP.md +36 -5
- package/dist/adapter-mantine-v8.cjs +2 -2
- package/dist/adapter-mantine-v8.cjs.map +1 -1
- package/dist/adapter-mantine-v8.css +1 -1
- package/dist/adapter-mantine-v8.js +3157 -3002
- package/dist/adapter-mantine-v8.js.map +1 -1
- package/dist/index.d.ts +191 -164
- package/llms.txt +1 -1
- package/package.json +3 -3
- package/recursica_brand.json +2 -2
- package/recursica_tokens.json +2 -2
- package/recursica_ui-kit.json +2 -2
- package/recursica_variables_scoped.css +7 -3
- package/src/components/Container/USAGE.md +0 -1
- package/src/components/Flex/USAGE.md +2 -1
- package/src/components/Group/USAGE.md +2 -1
- package/src/components/LayoutGrid/LAYOUT_GRID_IMPLEMENTATION_NOTES.md +88 -0
- package/src/components/LayoutGrid/LayoutGrid.columns.dom.test.tsx +66 -0
- package/src/components/LayoutGrid/LayoutGrid.module.css +48 -0
- package/src/components/LayoutGrid/LayoutGrid.stories.tsx +61 -0
- package/src/components/LayoutGrid/LayoutGrid.test.tsx +1 -0
- package/src/components/LayoutGrid/LayoutGrid.tsx +309 -0
- package/src/components/LayoutGrid/USAGE.md +76 -0
- package/src/components/Pagination/IMPLEMENTATION_NOTES.md +29 -8
- package/src/components/Pagination/Pagination.icons.tsx +0 -32
- package/src/components/Pagination/Pagination.manifest.dom.test.tsx +108 -0
- package/src/components/Pagination/Pagination.module.css +25 -155
- package/src/components/Pagination/Pagination.tsx +328 -197
- package/src/components/Pagination/USAGE.md +1 -0
- package/src/components/Stack/USAGE.md +2 -1
- package/src/components/index.ts +1 -1
- package/src/index.ts +1 -0
- package/src/utils/breakpointsFromRecManifest.test.ts +40 -0
- package/src/utils/breakpointsFromRecManifest.ts +75 -0
- package/src/utils/index.ts +1 -0
- package/src/components/Grid/GRID_IMPLEMENTATION_NOTES.md +0 -85
- package/src/components/Grid/Grid.module.css +0 -41
- package/src/components/Grid/Grid.stories.tsx +0 -200
- package/src/components/Grid/Grid.test.tsx +0 -1
- package/src/components/Grid/Grid.tsx +0 -179
- package/src/components/Grid/USAGE.md +0 -61
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
# LayoutGrid - Usage Guide
|
|
2
|
+
|
|
3
|
+
This document describes how to integrate and use the `LayoutGrid` component in your projects using `@recursica/adapter-mantine-v8`.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## 1. Import Reference
|
|
8
|
+
|
|
9
|
+
```tsx
|
|
10
|
+
import { LayoutGrid } from "@recursica/adapter-mantine-v8";
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
## 2. Basic Example
|
|
16
|
+
|
|
17
|
+
```tsx
|
|
18
|
+
import React from "react";
|
|
19
|
+
import { LayoutGrid } from "@recursica/adapter-mantine-v8";
|
|
20
|
+
|
|
21
|
+
export default function Demo() {
|
|
22
|
+
return (
|
|
23
|
+
// No layout props needed: columns, column-gutter, row-gutter and margin come from the design
|
|
24
|
+
// system's layout-grids tokens and change per breakpoint.
|
|
25
|
+
<LayoutGrid>
|
|
26
|
+
<LayoutGrid.Col span={3}>Half width at 6 columns</LayoutGrid.Col>
|
|
27
|
+
<LayoutGrid.Col span={{ xs: 6, sm: 3, md: 2 }}>
|
|
28
|
+
Responsive width
|
|
29
|
+
</LayoutGrid.Col>
|
|
30
|
+
</LayoutGrid>
|
|
31
|
+
);
|
|
32
|
+
}
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
---
|
|
36
|
+
|
|
37
|
+
## 3. Design System Integration
|
|
38
|
+
|
|
39
|
+
All Recursica components in the `@recursica/adapter-mantine-v8` package adhere strictly to design system spacing, scaling, and behavior patterns.
|
|
40
|
+
|
|
41
|
+
> [!IMPORTANT]
|
|
42
|
+
>
|
|
43
|
+
> - **Variables and Theming**: LayoutGrid follows the design system's own `layout-grids` tokens — columns, column-gutter, row-gutter and margin — applied automatically. Forge can define these per breakpoint, and the grid follows. None of them are configurable via props.
|
|
44
|
+
|
|
45
|
+
> [!NOTE] > **Recommended: build your Mantine theme's breakpoints from the Forge manifest with `breakpointsFromRecManifest`.** Responsive keys such as `{ base, sm, md }` on `LayoutGrid.Col` (and on Flex, Stack, Group) come from `theme.breakpoints`, while Forge's layout grids switch via plain CSS `@media`. If the two differ, tokens flip at Forge's width and props at the theme's. `breakpointsFromRecManifest(manifest)` (exported from `@recursica/adapter-mantine-v8`) gives you a `theme.breakpoints` object that matches Forge, so both switch at the same widths (Mantine keeps its default `xs`–`xl` keys alongside Forge's names, so use Forge's names in responsive props). See [SETUP.md](../../../SETUP.md):
|
|
46
|
+
>
|
|
47
|
+
> ```tsx
|
|
48
|
+
> import { createTheme } from "@mantine/core";
|
|
49
|
+
> import { breakpointsFromRecManifest } from "@recursica/adapter-mantine-v8";
|
|
50
|
+
> import manifest from "./recursica_manifest.json";
|
|
51
|
+
>
|
|
52
|
+
> const theme = createTheme({
|
|
53
|
+
> breakpoints: breakpointsFromRecManifest(manifest),
|
|
54
|
+
> });
|
|
55
|
+
> ```
|
|
56
|
+
|
|
57
|
+
---
|
|
58
|
+
|
|
59
|
+
## 4. Key Integration Features & Constraints
|
|
60
|
+
|
|
61
|
+
`LayoutGrid.Col`'s `span`, `offset`, `order`, `visibleFrom`, `hiddenFrom` match Mantine's own naming and
|
|
62
|
+
accept the same shapes, including per-breakpoint objects (`{ xs, sm, md, lg, xl }`) — all still a
|
|
63
|
+
straight Mantine pass-through for now. A formal `RecursicaLayoutGridColProps` contract in
|
|
64
|
+
`adapter-common` is scaffolded but not filled in yet (TODO, tracked in
|
|
65
|
+
`LAYOUT_GRID_IMPLEMENTATION_NOTES.md`).
|
|
66
|
+
|
|
67
|
+
`LayoutGrid` does not accept Mantine's `gutter` or `columns` props — column count, column-gutter,
|
|
68
|
+
row-gutter, and margin are design-system-managed (Forge-controlled, breakpoint-aware, applied via
|
|
69
|
+
CSS variables). For a fixed N-column grid unrelated to page layout, use Mantine's `Grid` directly.
|
|
70
|
+
|
|
71
|
+
`span` and `offset` (numeric, or a breakpoint map like `{ base: 12, md: 6 }`) are relative to
|
|
72
|
+
Forge's current column count, and `span` is clamped to it (span 6 fills the row at 3 columns).
|
|
73
|
+
Breakpoint maps switch at the app's Mantine theme breakpoints. `"auto"` and `"content"` don't
|
|
74
|
+
depend on the column count.
|
|
75
|
+
|
|
76
|
+
`grow`, `justify`, `align` are unchanged, matching Mantine's own naming.
|
|
@@ -1,16 +1,37 @@
|
|
|
1
1
|
# Pagination Implementation Notes
|
|
2
2
|
|
|
3
|
-
## Architecture
|
|
3
|
+
## Architecture: Recursica Buttons driven by the manifest
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
Forge's `ui-kit.components.pagination` defines its page and navigation controls as `Button`
|
|
6
|
+
variants (`active-pages`, `inactive-pages`, `navigation-controls`, each with a `selected-variants`
|
|
7
|
+
style and size). Pagination therefore renders Recursica `Button`s with those props and does no
|
|
8
|
+
button styling of its own: radius, padding, colors, hover and disabled all come from `Button`.
|
|
6
9
|
|
|
7
|
-
|
|
10
|
+
- `Pagination` reads the selected `style` and `size` per role from the manifest with
|
|
11
|
+
`useRecursicaManifest()` (`adapter-common`), provided by `RecursicaThemeProvider`'s `manifest`
|
|
12
|
+
prop. It throws if there is no manifest or if a role has no `selected-variants`. The values are
|
|
13
|
+
passed to `Button` as is, with no validation and no fallbacks.
|
|
14
|
+
- `content` (`label`, `icon-label`, `icon-only`) is not read: `Button` derives it from its own
|
|
15
|
+
children and icon, so page numbers are `label` and the navigation buttons are `icon-only`
|
|
16
|
+
(`icon-label` with `withLabels`).
|
|
8
17
|
|
|
9
|
-
|
|
18
|
+
## Why not Mantine's `Pagination.Control`
|
|
10
19
|
|
|
11
|
-
|
|
20
|
+
Mantine's `Pagination.Control` is not polymorphic, so it can't render our `Button`. The component is
|
|
21
|
+
built on `usePagination` from `@mantine/hooks` instead (page state, ranges, siblings/boundaries),
|
|
22
|
+
with its own context shared by `Pagination.Root`, `Items`, `Control`, `Dots`, `Next`, `Previous`,
|
|
23
|
+
`First` and `Last`. Page buttons set `aria-current="page"` on the active page, and the navigation
|
|
24
|
+
buttons have fixed `aria-label`s.
|
|
12
25
|
|
|
13
|
-
|
|
14
|
-
2. We inject `data-variant="text"` via `getControlProps` onto the navigation buttons so that they inherit the explicitly aliased text style variables (`navigation-controls`) defined by the UI Kit for pagination.
|
|
26
|
+
## Labels
|
|
15
27
|
|
|
16
|
-
|
|
28
|
+
`withLabels` adds a text label to each navigation button. `Previous`/`First` put the icon first
|
|
29
|
+
(`Button`'s `icon`); `Next`/`Last` put it after the label (`rightSection`, sized to the Button's
|
|
30
|
+
icon token via `[data-size]` in `Pagination.module.css`).
|
|
31
|
+
|
|
32
|
+
## Styling
|
|
33
|
+
|
|
34
|
+
`Pagination.module.css` only lays out the row (`item-gap`) and styles the dots (`dots-color`).
|
|
35
|
+
|
|
36
|
+
- The root is a `<nav aria-label="Pagination">` landmark, and each page button has `aria-label="Page N"`
|
|
37
|
+
(`Previous page`, `Next page`, etc. for the navigation buttons). Both can be overridden by props.
|
|
@@ -32,35 +32,3 @@ export const PaginationIcon = ({
|
|
|
32
32
|
<path d={paths[type as PaginationIconType]} fill="currentColor" />
|
|
33
33
|
</svg>
|
|
34
34
|
);
|
|
35
|
-
|
|
36
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
37
|
-
export const NextWithLabel = (props: any) => (
|
|
38
|
-
<div className={styles.iconWithLabel}>
|
|
39
|
-
<span>Next</span>
|
|
40
|
-
<PaginationIcon type="next" {...props} />
|
|
41
|
-
</div>
|
|
42
|
-
);
|
|
43
|
-
|
|
44
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
45
|
-
export const PrevWithLabel = (props: any) => (
|
|
46
|
-
<div className={styles.iconWithLabel}>
|
|
47
|
-
<PaginationIcon type="prev" {...props} />
|
|
48
|
-
<span>Prev</span>
|
|
49
|
-
</div>
|
|
50
|
-
);
|
|
51
|
-
|
|
52
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
53
|
-
export const FirstWithLabel = (props: any) => (
|
|
54
|
-
<div className={styles.iconWithLabel}>
|
|
55
|
-
<PaginationIcon type="first" {...props} />
|
|
56
|
-
<span>First</span>
|
|
57
|
-
</div>
|
|
58
|
-
);
|
|
59
|
-
|
|
60
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
61
|
-
export const LastWithLabel = (props: any) => (
|
|
62
|
-
<div className={styles.iconWithLabel}>
|
|
63
|
-
<span>Last</span>
|
|
64
|
-
<PaginationIcon type="last" {...props} />
|
|
65
|
-
</div>
|
|
66
|
-
);
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { describe, it, expect } from "vitest";
|
|
3
|
+
import { createRoot } from "react-dom/client";
|
|
4
|
+
import { flushSync } from "react-dom";
|
|
5
|
+
import { MantineProvider } from "@mantine/core";
|
|
6
|
+
import { RecursicaManifestContext } from "@recursica/adapter-common";
|
|
7
|
+
import { Pagination } from "./Pagination";
|
|
8
|
+
|
|
9
|
+
const role = (style: string, size: string) => ({
|
|
10
|
+
$extensions: {
|
|
11
|
+
"recursica.component": { "selected-variants": { style, size } },
|
|
12
|
+
},
|
|
13
|
+
});
|
|
14
|
+
const manifest = (props: Record<string, unknown>) => ({
|
|
15
|
+
"ui-kit": { components: { pagination: { properties: props } } },
|
|
16
|
+
});
|
|
17
|
+
const full = manifest({
|
|
18
|
+
"active-pages": role("solid", "small"),
|
|
19
|
+
"inactive-pages": role("outline", "small"),
|
|
20
|
+
"navigation-controls": role("text", "small"),
|
|
21
|
+
});
|
|
22
|
+
|
|
23
|
+
class Catch extends React.Component<
|
|
24
|
+
{ children: React.ReactNode },
|
|
25
|
+
{ error?: Error }
|
|
26
|
+
> {
|
|
27
|
+
state: { error?: Error } = {};
|
|
28
|
+
static getDerivedStateFromError(error: Error) {
|
|
29
|
+
return { error };
|
|
30
|
+
}
|
|
31
|
+
render() {
|
|
32
|
+
return this.state.error ? (
|
|
33
|
+
<span data-error>{this.state.error.message}</span>
|
|
34
|
+
) : (
|
|
35
|
+
this.props.children
|
|
36
|
+
);
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
function mount(m: Record<string, unknown> | undefined) {
|
|
41
|
+
const container = document.createElement("div");
|
|
42
|
+
document.body.appendChild(container);
|
|
43
|
+
const root = createRoot(container);
|
|
44
|
+
flushSync(() =>
|
|
45
|
+
root.render(
|
|
46
|
+
<MantineProvider>
|
|
47
|
+
<Catch>
|
|
48
|
+
<RecursicaManifestContext.Provider value={m}>
|
|
49
|
+
<Pagination total={5} defaultValue={2} />
|
|
50
|
+
</RecursicaManifestContext.Provider>
|
|
51
|
+
</Catch>
|
|
52
|
+
</MantineProvider>,
|
|
53
|
+
),
|
|
54
|
+
);
|
|
55
|
+
return {
|
|
56
|
+
container,
|
|
57
|
+
error: container.querySelector("[data-error]")?.textContent,
|
|
58
|
+
done: () => {
|
|
59
|
+
root.unmount();
|
|
60
|
+
container.remove();
|
|
61
|
+
},
|
|
62
|
+
};
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
describe("Pagination manifest variants", () => {
|
|
66
|
+
it("renders Buttons with the style and size the manifest selects per role", () => {
|
|
67
|
+
const { container, error, done } = mount(full);
|
|
68
|
+
expect(error).toBeUndefined();
|
|
69
|
+
const active = container.querySelector('[aria-current="page"]');
|
|
70
|
+
expect(active?.getAttribute("data-variant")).toBe("solid");
|
|
71
|
+
expect(active?.getAttribute("data-size")).toBe("small");
|
|
72
|
+
const inactive = [...container.querySelectorAll("button")].find(
|
|
73
|
+
(b) => b.textContent === "3",
|
|
74
|
+
);
|
|
75
|
+
expect(inactive?.getAttribute("data-variant")).toBe("outline");
|
|
76
|
+
const next = container.querySelector('[aria-label="Next page"]');
|
|
77
|
+
expect(next?.getAttribute("data-variant")).toBe("text");
|
|
78
|
+
expect(next?.getAttribute("data-content")).toBe("icon-only");
|
|
79
|
+
done();
|
|
80
|
+
});
|
|
81
|
+
|
|
82
|
+
it("renders a labelled nav with a labelled button per page", () => {
|
|
83
|
+
const { container, error, done } = mount(full);
|
|
84
|
+
expect(error).toBeUndefined();
|
|
85
|
+
expect(container.querySelector("nav")?.getAttribute("aria-label")).toBe(
|
|
86
|
+
"Pagination",
|
|
87
|
+
);
|
|
88
|
+
const three = [...container.querySelectorAll("button")].find(
|
|
89
|
+
(b) => b.textContent === "3",
|
|
90
|
+
);
|
|
91
|
+
expect(three?.getAttribute("aria-label")).toBe("Page 3");
|
|
92
|
+
done();
|
|
93
|
+
});
|
|
94
|
+
|
|
95
|
+
it("throws without a manifest", () => {
|
|
96
|
+
const { error, done } = mount(undefined);
|
|
97
|
+
expect(error).toMatch(/Recursica manifest/);
|
|
98
|
+
done();
|
|
99
|
+
});
|
|
100
|
+
|
|
101
|
+
it("throws when a role has no selected variants", () => {
|
|
102
|
+
const { error, done } = mount(
|
|
103
|
+
manifest({ "active-pages": role("solid", "small") }),
|
|
104
|
+
);
|
|
105
|
+
expect(error).toMatch(/navigation-controls selected-variants/);
|
|
106
|
+
done();
|
|
107
|
+
});
|
|
108
|
+
});
|
|
@@ -1,9 +1,5 @@
|
|
|
1
|
-
/*
|
|
2
|
-
*
|
|
3
|
-
* recursica-allow-brand: --recursica_brand_states_disabled
|
|
4
|
-
* recursica-allow-brand: --recursica_brand_states_hover_color
|
|
5
|
-
* recursica-allow-brand: --recursica_brand_states_hover_opacity
|
|
6
|
-
*/
|
|
1
|
+
/* The page and navigation buttons are Recursica Buttons (see Pagination.tsx), so this file only
|
|
2
|
+
* lays out the row and styles the dots and the labelled-icon wrapper. */
|
|
7
3
|
|
|
8
4
|
.root {
|
|
9
5
|
display: flex;
|
|
@@ -11,178 +7,52 @@
|
|
|
11
7
|
gap: var(--recursica_ui-kit_components_pagination_properties_item-gap);
|
|
12
8
|
}
|
|
13
9
|
|
|
14
|
-
.
|
|
15
|
-
|
|
16
|
-
margin: 0;
|
|
17
|
-
border-style: solid;
|
|
18
|
-
position: relative;
|
|
19
|
-
transition: all 0.2s ease;
|
|
20
|
-
overflow: hidden;
|
|
10
|
+
/* Dots: sized like the page buttons around them (the inactive-pages size from the manifest). */
|
|
11
|
+
.dots {
|
|
21
12
|
display: inline-flex;
|
|
22
13
|
align-items: center;
|
|
23
14
|
justify-content: center;
|
|
24
|
-
|
|
25
|
-
/* Typography */
|
|
26
|
-
font-family: var(
|
|
27
|
-
--recursica_ui-kit_components_button_variants_sizes_default_properties_text_font-family
|
|
28
|
-
);
|
|
29
|
-
font-size: var(
|
|
30
|
-
--recursica_ui-kit_components_button_variants_sizes_default_properties_text_font-size
|
|
31
|
-
);
|
|
32
|
-
font-style: var(
|
|
33
|
-
--recursica_ui-kit_components_button_variants_sizes_default_properties_text_font-style
|
|
34
|
-
);
|
|
35
|
-
font-weight: var(
|
|
36
|
-
--recursica_ui-kit_components_button_variants_sizes_default_properties_text_font-weight
|
|
37
|
-
);
|
|
38
|
-
letter-spacing: var(
|
|
39
|
-
--recursica_ui-kit_components_button_variants_sizes_default_properties_text_letter-spacing
|
|
40
|
-
);
|
|
41
|
-
line-height: var(
|
|
42
|
-
--recursica_ui-kit_components_button_variants_sizes_default_properties_text_line-height
|
|
43
|
-
);
|
|
44
|
-
text-decoration: var(
|
|
45
|
-
--recursica_ui-kit_components_button_variants_sizes_default_properties_text_text-decoration
|
|
46
|
-
);
|
|
47
|
-
text-transform: var(
|
|
48
|
-
--recursica_ui-kit_components_button_variants_sizes_default_properties_text_text-transform
|
|
49
|
-
);
|
|
50
|
-
|
|
51
|
-
/* Dimensions */
|
|
52
|
-
border-radius: var(
|
|
53
|
-
--recursica_ui-kit_components_button_variants_content_icon-only_variants_sizes_default_properties_border-radius
|
|
54
|
-
);
|
|
55
15
|
height: var(
|
|
56
16
|
--recursica_ui-kit_components_button_variants_sizes_default_properties_height
|
|
57
17
|
);
|
|
58
18
|
min-width: var(
|
|
59
19
|
--recursica_ui-kit_components_button_variants_sizes_default_properties_min-width
|
|
60
20
|
);
|
|
61
|
-
padding: 0
|
|
62
|
-
var(
|
|
63
|
-
--recursica_ui-kit_components_button_variants_sizes_default_properties_horizontal-padding
|
|
64
|
-
);
|
|
65
|
-
|
|
66
|
-
/* Base Inactive Style: Outline */
|
|
67
|
-
border-width: var(
|
|
68
|
-
--recursica_ui-kit_components_button_variants_styles_outline_properties_border-size
|
|
69
|
-
);
|
|
70
|
-
box-shadow: var(
|
|
71
|
-
--recursica_ui-kit_components_button_variants_styles_outline_properties_elevation
|
|
72
|
-
);
|
|
73
|
-
background-color: var(
|
|
74
|
-
--recursica_ui-kit_components_button_variants_styles_outline_properties_colors_background-color
|
|
75
|
-
);
|
|
76
|
-
border-color: var(
|
|
77
|
-
--recursica_ui-kit_components_button_variants_styles_outline_properties_colors_border-color
|
|
78
|
-
);
|
|
79
|
-
color: var(
|
|
80
|
-
--recursica_ui-kit_components_button_variants_styles_outline_properties_colors_text-color
|
|
81
|
-
);
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
.control:disabled {
|
|
85
|
-
opacity: var(--recursica_brand_states_disabled);
|
|
86
|
-
cursor: not-allowed;
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
/* Hover Overlay: no per-variant hover-color/hover-opacity tokens exist anymore; use the
|
|
90
|
-
generic overlay tokens shared across components (same as Button). */
|
|
91
|
-
.control::after {
|
|
92
|
-
content: "";
|
|
93
|
-
position: absolute;
|
|
94
|
-
inset: 0;
|
|
95
|
-
border-radius: inherit;
|
|
96
|
-
z-index: 0;
|
|
97
|
-
pointer-events: none;
|
|
98
|
-
transition: opacity 150ms ease;
|
|
99
|
-
opacity: 0;
|
|
100
|
-
background-color: var(--recursica_brand_states_hover_color);
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
.control:hover:not(:disabled)::after {
|
|
104
|
-
opacity: var(--recursica_brand_states_hover_opacity);
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
/* Active Style: Solid */
|
|
108
|
-
.control[data-active] {
|
|
109
|
-
border-width: var(
|
|
110
|
-
--recursica_ui-kit_components_button_variants_styles_solid_properties_border-size
|
|
111
|
-
);
|
|
112
|
-
box-shadow: var(
|
|
113
|
-
--recursica_ui-kit_components_button_variants_styles_solid_properties_elevation
|
|
114
|
-
);
|
|
115
|
-
background-color: var(
|
|
116
|
-
--recursica_ui-kit_components_button_variants_styles_solid_properties_colors_background-color
|
|
117
|
-
);
|
|
118
|
-
border-color: var(
|
|
119
|
-
--recursica_ui-kit_components_button_variants_styles_solid_properties_colors_border-color
|
|
120
|
-
);
|
|
121
21
|
color: var(
|
|
122
|
-
--recursica_ui-
|
|
22
|
+
--recursica_ui-kit_components_pagination_properties_colors_dots-color
|
|
123
23
|
);
|
|
124
24
|
}
|
|
125
25
|
|
|
126
|
-
|
|
127
|
-
.control[data-variant="text"] {
|
|
128
|
-
border-width: var(
|
|
129
|
-
--recursica_ui-kit_components_button_variants_styles_text_properties_border-size
|
|
130
|
-
);
|
|
131
|
-
box-shadow: var(
|
|
132
|
-
--recursica_ui-kit_components_button_variants_styles_text_properties_elevation
|
|
133
|
-
);
|
|
134
|
-
background-color: var(
|
|
135
|
-
--recursica_ui-kit_components_button_variants_styles_text_properties_colors_background-color
|
|
136
|
-
);
|
|
137
|
-
border-color: var(
|
|
138
|
-
--recursica_ui-kit_components_button_variants_styles_text_properties_colors_border-color
|
|
139
|
-
);
|
|
140
|
-
color: var(
|
|
141
|
-
--recursica_ui-kit_components_button_variants_styles_text_properties_colors_text-color
|
|
142
|
-
);
|
|
143
|
-
|
|
144
|
-
/* Also explicitly inherit navigation sizes incase they differ from pages */
|
|
145
|
-
border-radius: var(
|
|
146
|
-
--recursica_ui-kit_components_button_variants_content_icon-only_variants_sizes_default_properties_border-radius
|
|
147
|
-
);
|
|
26
|
+
.dots[data-size="small"] {
|
|
148
27
|
height: var(
|
|
149
|
-
--recursica_ui-
|
|
28
|
+
--recursica_ui-kit_components_button_variants_sizes_small_properties_height
|
|
150
29
|
);
|
|
151
30
|
min-width: var(
|
|
152
|
-
--recursica_ui-
|
|
31
|
+
--recursica_ui-kit_components_button_variants_sizes_small_properties_min-width
|
|
153
32
|
);
|
|
154
|
-
padding: 0
|
|
155
|
-
var(
|
|
156
|
-
--recursica_ui-kit_components_button_variants_sizes_default_properties_horizontal-padding
|
|
157
|
-
);
|
|
158
33
|
}
|
|
159
34
|
|
|
160
|
-
/*
|
|
161
|
-
.
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
justify-content: center;
|
|
165
|
-
height: var(
|
|
166
|
-
--recursica_ui-kit_components_button_variants_sizes_default_properties_height
|
|
167
|
-
);
|
|
168
|
-
min-width: var(
|
|
169
|
-
--recursica_ui-kit_components_button_variants_sizes_default_properties_min-width
|
|
170
|
-
);
|
|
171
|
-
color: var(
|
|
172
|
-
--recursica_ui-kit_components_pagination_properties_colors_dots-color
|
|
173
|
-
);
|
|
35
|
+
/* Icons: sized by the Button's own icon wrapper (left icons) or by its size (right icons). */
|
|
36
|
+
.baseIcon {
|
|
37
|
+
width: 100%;
|
|
38
|
+
height: 100%;
|
|
174
39
|
}
|
|
175
40
|
|
|
176
|
-
|
|
177
|
-
.iconWithLabel {
|
|
41
|
+
.rightIcon {
|
|
178
42
|
display: flex;
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
43
|
+
width: var(
|
|
44
|
+
--recursica_ui-kit_components_button_variants_sizes_default_properties_icon
|
|
45
|
+
);
|
|
46
|
+
height: var(
|
|
47
|
+
--recursica_ui-kit_components_button_variants_sizes_default_properties_icon
|
|
182
48
|
);
|
|
183
49
|
}
|
|
184
50
|
|
|
185
|
-
.
|
|
186
|
-
width:
|
|
187
|
-
|
|
51
|
+
[data-size="small"] .rightIcon {
|
|
52
|
+
width: var(
|
|
53
|
+
--recursica_ui-kit_components_button_variants_sizes_small_properties_icon
|
|
54
|
+
);
|
|
55
|
+
height: var(
|
|
56
|
+
--recursica_ui-kit_components_button_variants_sizes_small_properties_icon
|
|
57
|
+
);
|
|
188
58
|
}
|