katalyst-koi 4.18.1 → 5.0.0.alpha.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.
- checksums.yaml +4 -4
- data/app/assets/images/koi/icons/add.svg +3 -0
- data/app/assets/images/koi/icons/close.svg +1 -0
- data/app/assets/images/koi/koi.png +0 -0
- data/app/assets/javascripts/koi/controllers/file_field_controller.js +2 -2
- data/app/assets/javascripts/koi/controllers/index.js +0 -3
- data/app/assets/javascripts/koi/controllers/koi/modal_controller.js +40 -0
- data/app/assets/javascripts/koi/controllers/navigation_controller.js +14 -21
- data/app/assets/javascripts/koi/controllers/webauthn_registration_controller.js +4 -1
- data/app/assets/stylesheets/koi/blocks/actions.css +8 -0
- data/app/assets/stylesheets/koi/blocks/application-header.css +15 -0
- data/app/assets/stylesheets/koi/blocks/application-navigation.css +54 -0
- data/app/assets/stylesheets/koi/blocks/button.css +90 -0
- data/app/assets/stylesheets/koi/blocks/flash.css +19 -0
- data/app/assets/stylesheets/koi/blocks/icon.css +15 -0
- data/app/assets/stylesheets/koi/blocks/index.css +13 -0
- data/app/assets/stylesheets/koi/blocks/modal.css +26 -0
- data/app/assets/stylesheets/koi/blocks/navigation.css +23 -0
- data/app/assets/stylesheets/koi/blocks/page-header.css +31 -0
- data/app/assets/stylesheets/koi/blocks/pagy.css +82 -0
- data/app/assets/stylesheets/koi/blocks/prose.css +37 -0
- data/app/assets/stylesheets/koi/blocks/tables/index.css +4 -0
- data/app/assets/stylesheets/koi/{components/_query.scss → blocks/tables/query.css} +13 -13
- data/app/assets/stylesheets/koi/{base/_tables.scss → blocks/tables/table.css} +12 -60
- data/app/assets/stylesheets/koi/compositions/cover.css +17 -0
- data/app/assets/stylesheets/koi/{base/_flow.scss → compositions/flow.css} +1 -1
- data/app/assets/stylesheets/koi/compositions/index.css +4 -0
- data/app/assets/stylesheets/koi/compositions/wrapper.css +11 -0
- data/app/assets/stylesheets/koi/forms/caption.css +22 -0
- data/app/assets/stylesheets/koi/forms/checkboxes.css +153 -0
- data/app/assets/stylesheets/koi/forms/date-input.css +12 -0
- data/app/assets/stylesheets/koi/{components/_document-field.scss → forms/document-field.css} +20 -15
- data/app/assets/stylesheets/koi/forms/errors.css +38 -0
- data/app/assets/stylesheets/koi/forms/fieldset.css +73 -0
- data/app/assets/stylesheets/koi/forms/file-upload.css +20 -0
- data/app/assets/stylesheets/koi/forms/form-group.css +19 -0
- data/app/assets/stylesheets/koi/forms/hint.css +11 -0
- data/app/assets/stylesheets/koi/forms/image-field.css +96 -0
- data/app/assets/stylesheets/koi/forms/index.css +44 -0
- data/app/assets/stylesheets/koi/forms/input.css +194 -0
- data/app/assets/stylesheets/koi/forms/label.css +43 -0
- data/app/assets/stylesheets/koi/forms/password.css +18 -0
- data/app/assets/stylesheets/koi/forms/radios.css +162 -0
- data/app/assets/stylesheets/koi/forms/select.css +18 -0
- data/app/assets/stylesheets/koi/forms/textarea.css +3 -0
- data/app/assets/stylesheets/koi/forms/trix.css +33 -0
- data/app/assets/stylesheets/koi/global/fonts.css +22 -0
- data/app/assets/stylesheets/koi/global/global-styles.css +297 -0
- data/app/assets/stylesheets/koi/global/reset.css +98 -0
- data/app/assets/stylesheets/koi/global/variables.css +97 -0
- data/app/assets/stylesheets/koi/icons.css +14 -0
- data/app/assets/stylesheets/koi/index.css +17 -0
- data/app/assets/stylesheets/koi/login.css +26 -0
- data/app/assets/stylesheets/koi/utilities/index.css +1 -0
- data/app/assets/stylesheets/koi/utilities/visually-hidden.css +18 -0
- data/app/components/concerns/koi/tables/cells.rb +3 -3
- data/app/components/koi/header_component.html.erb +12 -11
- data/app/components/koi/header_component.rb +2 -0
- data/app/components/koi/table_component.rb +8 -0
- data/app/controllers/admin/admin_users_controller.rb +24 -18
- data/app/controllers/admin/application_controller.rb +1 -3
- data/app/controllers/admin/credentials_controller.rb +18 -14
- data/app/controllers/admin/otps_controller.rb +15 -13
- data/app/controllers/admin/sessions_controller.rb +12 -1
- data/app/controllers/admin/url_rewrites_controller.rb +19 -17
- data/app/controllers/admin/well_knowns_controller.rb +20 -18
- data/app/controllers/concerns/koi/controller.rb +37 -0
- data/app/helpers/koi/form_helper.rb +18 -0
- data/app/helpers/koi/header_helper.rb +122 -0
- data/app/helpers/koi/index_actions_helper.rb +3 -2
- data/app/helpers/koi/modal_helper.rb +71 -0
- data/app/models/admin/user.rb +7 -1
- data/app/models/url_rewrite.rb +1 -9
- data/app/views/admin/admin_users/_form.html+self.erb +8 -0
- data/app/views/admin/admin_users/_form.html.erb +8 -0
- data/app/views/admin/admin_users/archived.html.erb +7 -4
- data/app/views/admin/admin_users/edit.html+self.erb +12 -0
- data/app/views/admin/admin_users/edit.html.erb +13 -8
- data/app/views/admin/admin_users/index.html.erb +10 -5
- data/app/views/admin/admin_users/new.html.erb +8 -8
- data/app/views/admin/admin_users/show.html+self.erb +26 -14
- data/app/views/admin/admin_users/show.html.erb +22 -20
- data/app/views/admin/credentials/_credentials.html+self.erb +8 -6
- data/app/views/admin/credentials/_credentials.html.erb +3 -1
- data/app/views/admin/credentials/create.turbo_stream.erb +4 -3
- data/app/views/admin/credentials/destroy.turbo_stream.erb +4 -2
- data/app/views/admin/credentials/new.html.erb +42 -36
- data/app/views/admin/dashboards/show.html.erb +13 -1
- data/app/views/admin/otps/_form.html.erb +7 -7
- data/app/views/admin/otps/create.turbo_stream.erb +3 -3
- data/app/views/admin/otps/new.html.erb +5 -3
- data/app/views/admin/sessions/new.html.erb +2 -3
- data/app/views/admin/sessions/otp.html.erb +1 -3
- data/app/views/admin/sessions/password.html.erb +1 -3
- data/app/views/admin/tokens/show.html.erb +4 -6
- data/app/views/admin/url_rewrites/_form.html.erb +9 -0
- data/app/views/admin/url_rewrites/edit.html.erb +13 -9
- data/app/views/admin/url_rewrites/index.html.erb +10 -7
- data/app/views/admin/url_rewrites/new.html.erb +8 -8
- data/app/views/admin/url_rewrites/show.html.erb +17 -12
- data/app/views/admin/well_knowns/_form.html.erb +9 -0
- data/app/views/admin/well_knowns/edit.html.erb +13 -9
- data/app/views/admin/well_knowns/index.html.erb +8 -5
- data/app/views/admin/well_knowns/new.html.erb +8 -8
- data/app/views/admin/well_knowns/show.html.erb +14 -13
- data/app/views/katalyst/content/asides/_aside.html+form.erb +6 -4
- data/app/views/katalyst/content/columns/_column.html+form.erb +5 -3
- data/app/views/katalyst/content/contents/_content.html+form.erb +8 -6
- data/app/views/katalyst/content/figures/_figure.html+form.erb +8 -5
- data/app/views/katalyst/content/groups/_group.html+form.erb +5 -3
- data/app/views/katalyst/content/items/_item.html+form.erb +5 -3
- data/app/views/katalyst/content/sections/_section.html+form.erb +5 -3
- data/app/views/katalyst/content/tables/_table.html+form.erb +16 -11
- data/app/views/katalyst/navigation/items/_button.html.erb +6 -12
- data/app/views/katalyst/navigation/items/_heading.html.erb +3 -10
- data/app/views/katalyst/navigation/items/_link.html.erb +6 -11
- data/app/views/katalyst/navigation/menus/edit.html.erb +10 -6
- data/app/views/katalyst/navigation/menus/index.html.erb +4 -2
- data/app/views/katalyst/navigation/menus/new.html.erb +5 -3
- data/app/views/katalyst/navigation/menus/show.html.erb +8 -7
- data/app/views/layouts/koi/_application_header.html.erb +20 -0
- data/app/views/layouts/koi/_application_navigation.html.erb +34 -0
- data/app/views/layouts/koi/_flash.html.erb +6 -3
- data/app/views/layouts/koi/_navigation_header.html.erb +0 -2
- data/app/views/layouts/koi/application.html.erb +22 -27
- data/app/views/layouts/koi/frame.html.erb +1 -3
- data/app/views/layouts/koi/login.html.erb +12 -5
- data/config/locales/koi.en.yml +9 -1
- data/config/routes.rb +1 -1
- data/lib/generators/koi/admin/admin_generator.rb +3 -13
- data/lib/generators/koi/admin_controller/admin_controller_generator.rb +6 -16
- data/lib/generators/koi/admin_controller/templates/controller.rb.tt +82 -18
- data/lib/generators/koi/admin_controller/templates/controller_spec.rb.tt +113 -47
- data/lib/generators/koi/admin_route/admin_route_generator.rb +60 -6
- data/lib/generators/koi/admin_views/USAGE +18 -7
- data/lib/generators/koi/admin_views/admin_views_generator.rb +19 -11
- data/lib/generators/koi/admin_views/templates/_form.html.erb.tt +8 -0
- data/lib/generators/koi/admin_views/templates/archived.html.erb.tt +33 -0
- data/lib/generators/koi/admin_views/templates/edit.html.erb.tt +17 -9
- data/lib/generators/koi/admin_views/templates/index.html.erb.tt +31 -3
- data/lib/generators/koi/admin_views/templates/new.html.erb.tt +8 -8
- data/lib/generators/koi/admin_views/templates/show.html.erb.tt +15 -18
- data/lib/generators/koi/helpers/attribute_helpers.rb +147 -0
- data/lib/generators/koi/helpers/attribute_types.rb +218 -0
- data/lib/generators/koi/helpers/resource_helpers.rb +121 -0
- data/lib/generators/koi/{active_record/active_record_generator.rb → model/model_generator.rb} +1 -1
- data/lib/koi/config.rb +3 -1
- data/lib/koi/engine.rb +0 -9
- data/lib/koi/form/builder.rb +4 -4
- data/lib/koi/form/content.rb +55 -0
- data/lib/koi/form/elements/document.rb +1 -1
- data/lib/koi/form/elements/image.rb +1 -1
- data/lib/koi/form_builder.rb +1 -0
- data/lib/koi/menu.rb +14 -1
- data/spec/factories/admins.rb +1 -1
- metadata +90 -103
- data/app/assets/builds/koi/admin.css +0 -1
- data/app/assets/stylesheets/koi/admin.scss +0 -27
- data/app/assets/stylesheets/koi/base/_button.scss +0 -122
- data/app/assets/stylesheets/koi/base/_icon.scss +0 -29
- data/app/assets/stylesheets/koi/base/_index.scss +0 -21
- data/app/assets/stylesheets/koi/base/_input.scss +0 -19
- data/app/assets/stylesheets/koi/base/_link.scss +0 -26
- data/app/assets/stylesheets/koi/base/_list.scss +0 -11
- data/app/assets/stylesheets/koi/base/_typography.scss +0 -160
- data/app/assets/stylesheets/koi/components/_actions-group.scss +0 -7
- data/app/assets/stylesheets/koi/components/_image-field.scss +0 -95
- data/app/assets/stylesheets/koi/components/_index.scss +0 -9
- data/app/assets/stylesheets/koi/components/_pagy.scss +0 -29
- data/app/assets/stylesheets/koi/components/_summary-list.scss +0 -40
- data/app/assets/stylesheets/koi/layouts/_banner.scss +0 -7
- data/app/assets/stylesheets/koi/layouts/_content.scss +0 -40
- data/app/assets/stylesheets/koi/layouts/_flash.scss +0 -41
- data/app/assets/stylesheets/koi/layouts/_header.scss +0 -61
- data/app/assets/stylesheets/koi/layouts/_index.scss +0 -48
- data/app/assets/stylesheets/koi/layouts/_main.scss +0 -23
- data/app/assets/stylesheets/koi/layouts/_navigation.scss +0 -180
- data/app/assets/stylesheets/koi/layouts/_stack.scss +0 -13
- data/app/assets/stylesheets/koi/pages/_index.scss +0 -1
- data/app/assets/stylesheets/koi/pages/_login.scss +0 -46
- data/app/assets/stylesheets/koi/themes/_content.scss +0 -62
- data/app/assets/stylesheets/koi/themes/_govuk.scss +0 -56
- data/app/assets/stylesheets/koi/themes/_index.scss +0 -5
- data/app/assets/stylesheets/koi/themes/_kpop.scss +0 -5
- data/app/assets/stylesheets/koi/themes/_navigation.scss +0 -5
- data/app/assets/stylesheets/koi/themes/_trix.scss +0 -32
- data/app/assets/stylesheets/koi/utils/_breakpoints.scss +0 -13
- data/app/assets/stylesheets/koi/utils/_hide.scss +0 -11
- data/app/assets/stylesheets/koi/utils/_index.scss +0 -2
- data/app/assets/stylesheets/koi/utils/_typography.scss +0 -42
- data/app/components/koi/content/editor/item_form_component.html.erb +0 -11
- data/app/components/koi/content/editor/item_form_component.rb +0 -94
- data/app/components/koi/summary_list/attachment_component.rb +0 -47
- data/app/components/koi/summary_list/base.rb +0 -59
- data/app/components/koi/summary_list/boolean_component.rb +0 -15
- data/app/components/koi/summary_list/date_component.rb +0 -17
- data/app/components/koi/summary_list/datetime_component.rb +0 -17
- data/app/components/koi/summary_list/item_component.rb +0 -26
- data/app/components/koi/summary_list/number_component.rb +0 -21
- data/app/components/koi/summary_list/rich_text_component.rb +0 -8
- data/app/components/koi/summary_list/text_component.rb +0 -8
- data/app/components/koi/summary_list_component.html.erb +0 -5
- data/app/components/koi/summary_list_component.rb +0 -75
- data/app/controllers/concerns/koi/controller/is_admin_controller.rb +0 -66
- data/app/helpers/koi/application_helper.rb +0 -7
- data/app/helpers/koi/date_helper.rb +0 -26
- data/app/helpers/koi/definition_list_helper.rb +0 -10
- data/app/views/admin/admin_users/_fields.html+self.erb +0 -3
- data/app/views/admin/admin_users/_fields.html.erb +0 -3
- data/app/views/admin/url_rewrites/_fields.html.erb +0 -4
- data/app/views/admin/well_knowns/_fields.html.erb +0 -6
- data/app/views/layouts/koi/_environment.html.erb +0 -4
- data/app/views/layouts/koi/_header.html.erb +0 -11
- data/app/views/layouts/koi/_navigation.html.erb +0 -23
- data/app/views/layouts/koi/_navigation_collapse.html.erb +0 -3
- data/lib/generators/koi/admin_views/templates/_fields.html.erb.tt +0 -3
- data/lib/generators/koi/helpers/admin_generator_attributes.rb +0 -66
- data/lib/koi/extensions/dartsass.rb +0 -23
- /data/app/assets/stylesheets/koi/{components/_clipboard.scss → blocks/clipboard.css} +0 -0
- /data/app/assets/stylesheets/koi/{components/_index-actions.scss → blocks/index-actions.css} +0 -0
- /data/app/assets/stylesheets/koi/{components/_toolbar.scss → blocks/toolbar.css} +0 -0
- /data/app/assets/stylesheets/koi/{base/_repel.scss → compositions/repel.css} +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3777de240276e451603985d91320a6573c65b65f24513bd1126f68d0804b4b86
|
4
|
+
data.tar.gz: 51aa501b880d82877857a799d637129d27b6f6f110eb0d61ebeaaca96679aee0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a3afbbe982db35e56dbb7f6719648a43e51d516306f75890d471e7564208b13e9287386b6507b1b89882528edb5366a973785f9ff09f38f16a8d3e032be1ad06
|
7
|
+
data.tar.gz: b54671b47ac0f51359c1980920c844d73fb5f3ad8b6abe2ac656a2de9a5d801fd09e9e355e79d6b6627597ae589da67f9f6dedbbaf0caba1824775020ac12c23
|
@@ -0,0 +1 @@
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" stroke="#000" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" viewBox="0 0 16 16"><path d="M15 1 1 15M1 1l14 14"/></svg>
|
Binary file
|
@@ -19,7 +19,7 @@ export default class FileFieldController extends Controller {
|
|
19
19
|
if (this.hasDestroyTarget) {
|
20
20
|
this.destroyTarget.value = false;
|
21
21
|
}
|
22
|
-
this.previewTarget.
|
22
|
+
this.previewTarget.removeAttribute("hidden");
|
23
23
|
|
24
24
|
// Show preview only if a file has been selected in the file picker popup. If cancelled, show previous file or do
|
25
25
|
// not show preview at all
|
@@ -46,7 +46,7 @@ export default class FileFieldController extends Controller {
|
|
46
46
|
this.destroyTarget.value = true;
|
47
47
|
}
|
48
48
|
if (this.hasPreviewTarget) {
|
49
|
-
this.previewTarget.
|
49
|
+
this.previewTarget.setAttribute("hidden", "");
|
50
50
|
this.setPreviewContent("");
|
51
51
|
}
|
52
52
|
if (this.previousInput) {
|
@@ -0,0 +1,40 @@
|
|
1
|
+
import { Controller } from "@hotwired/stimulus";
|
2
|
+
|
3
|
+
export default class ModalController extends Controller {
|
4
|
+
static targets = ["dialog"];
|
5
|
+
|
6
|
+
connect() {
|
7
|
+
this.element.addEventListener("turbo:submit-end", this.onSubmit);
|
8
|
+
}
|
9
|
+
|
10
|
+
disconnect() {
|
11
|
+
this.element.removeEventListener("turbo:submit-end", this.onSubmit);
|
12
|
+
}
|
13
|
+
|
14
|
+
click(e) {
|
15
|
+
if (e.target.tagName === "DIALOG") this.dismiss();
|
16
|
+
}
|
17
|
+
|
18
|
+
dismiss() {
|
19
|
+
if (!this.dialogTarget) return;
|
20
|
+
if (!this.dialogTarget.open) this.dialogTarget.close();
|
21
|
+
|
22
|
+
this.element.removeAttribute("src");
|
23
|
+
this.dialogTarget.remove();
|
24
|
+
}
|
25
|
+
|
26
|
+
dialogTargetConnected(dialog) {
|
27
|
+
dialog.showModal();
|
28
|
+
}
|
29
|
+
|
30
|
+
onSubmit = (event) => {
|
31
|
+
if (
|
32
|
+
event.detail.success &&
|
33
|
+
"closeDialog" in event.detail.formSubmission?.submitter?.dataset
|
34
|
+
) {
|
35
|
+
this.dialogTarget.close();
|
36
|
+
this.element.removeAttribute("src");
|
37
|
+
this.dialogTarget.remove();
|
38
|
+
}
|
39
|
+
};
|
40
|
+
}
|
@@ -3,25 +3,6 @@ import { Controller } from "@hotwired/stimulus";
|
|
3
3
|
export default class NavigationController extends Controller {
|
4
4
|
static targets = ["filter"];
|
5
5
|
|
6
|
-
connect() {
|
7
|
-
// using JS registration to make controller easier to add to dom
|
8
|
-
this.element.addEventListener(
|
9
|
-
"turbo:before-morph-attribute",
|
10
|
-
this.onMorphAttribute,
|
11
|
-
);
|
12
|
-
}
|
13
|
-
|
14
|
-
disconnected() {
|
15
|
-
this.element.removeEventListener(
|
16
|
-
"turbo:before-morph-attribute",
|
17
|
-
this.onMorphAttribute,
|
18
|
-
);
|
19
|
-
}
|
20
|
-
|
21
|
-
focus() {
|
22
|
-
this.filterTarget.focus();
|
23
|
-
}
|
24
|
-
|
25
6
|
filter() {
|
26
7
|
const filter = this.filterTarget.value;
|
27
8
|
this.clearFilter(filter);
|
@@ -90,14 +71,26 @@ export default class NavigationController extends Controller {
|
|
90
71
|
}
|
91
72
|
|
92
73
|
toggle() {
|
93
|
-
this.element.
|
74
|
+
this.element.open ? this.close() : this.open();
|
75
|
+
}
|
76
|
+
|
77
|
+
open() {
|
78
|
+
if (!this.element.open) this.element.showModal();
|
79
|
+
}
|
80
|
+
|
81
|
+
close() {
|
82
|
+
if (this.element.open) this.element.close();
|
83
|
+
}
|
84
|
+
|
85
|
+
click(e) {
|
86
|
+
if (e.target === this.element) this.close();
|
94
87
|
}
|
95
88
|
|
96
89
|
onMorphAttribute = (e) => {
|
97
90
|
if (e.target !== this.element) return;
|
98
91
|
|
99
92
|
switch (e.detail.attributeName) {
|
100
|
-
case "
|
93
|
+
case "open":
|
101
94
|
e.preventDefault();
|
102
95
|
}
|
103
96
|
};
|
@@ -13,7 +13,10 @@ export default class WebauthnRegistrationController extends Controller {
|
|
13
13
|
static targets = ["intro", "nickname", "response"];
|
14
14
|
|
15
15
|
submit(e) {
|
16
|
-
if (
|
16
|
+
if (
|
17
|
+
this.responseTarget.value === "" &&
|
18
|
+
e.submitter.formMethod !== "dialog"
|
19
|
+
) {
|
17
20
|
e.preventDefault();
|
18
21
|
this.createCredential();
|
19
22
|
}
|
@@ -0,0 +1,15 @@
|
|
1
|
+
.application-header {
|
2
|
+
--repel-vertical-alignment: baseline;
|
3
|
+
background-color: var(--color-dark);
|
4
|
+
color: var(--color-light);
|
5
|
+
padding-block: var(--space-2xs);
|
6
|
+
|
7
|
+
kbd {
|
8
|
+
color: var(--color-mid);
|
9
|
+
}
|
10
|
+
|
11
|
+
.brand {
|
12
|
+
color: white;
|
13
|
+
text-decoration: none;
|
14
|
+
}
|
15
|
+
}
|
@@ -0,0 +1,54 @@
|
|
1
|
+
.application-navigation {
|
2
|
+
--navigation-width: 30rem;
|
3
|
+
|
4
|
+
width: 100svw;
|
5
|
+
max-width: min(calc(100vw - var(--gutter) * 2), var(--navigation-width));
|
6
|
+
height: 100svh;
|
7
|
+
max-height: unset;
|
8
|
+
position: fixed;
|
9
|
+
top: 0;
|
10
|
+
margin-inline-end: 0;
|
11
|
+
border: none;
|
12
|
+
background: var(--color-light);
|
13
|
+
box-shadow: -5px 0 15px rgba(0, 0, 0, 0.2);
|
14
|
+
transform: translateX(100%);
|
15
|
+
transition:
|
16
|
+
display var(--transition-fade) allow-discrete,
|
17
|
+
overlay var(--transition-fade) allow-discrete,
|
18
|
+
transform var(--transition-movement);
|
19
|
+
font-size: var(--size-step-0);
|
20
|
+
|
21
|
+
--flow-space: var(--space-m);
|
22
|
+
|
23
|
+
a[href] {
|
24
|
+
text-decoration: none;
|
25
|
+
}
|
26
|
+
}
|
27
|
+
|
28
|
+
.application-navigation[open] {
|
29
|
+
transform: translateX(0);
|
30
|
+
}
|
31
|
+
|
32
|
+
@starting-style {
|
33
|
+
.application-navigation[open] {
|
34
|
+
transform: translateX(100%);
|
35
|
+
}
|
36
|
+
}
|
37
|
+
|
38
|
+
.application-navigation::backdrop {
|
39
|
+
background-color: rgb(0 0 0 / 0%);
|
40
|
+
transition:
|
41
|
+
background-color var(--transition-fade),
|
42
|
+
display var(--transition-fade) allow-discrete,
|
43
|
+
overlay var(--transition-fade) allow-discrete;
|
44
|
+
}
|
45
|
+
|
46
|
+
.application-navigation[open]::backdrop {
|
47
|
+
background-color: rgb(0 0 0 / 40%);
|
48
|
+
}
|
49
|
+
|
50
|
+
@starting-style {
|
51
|
+
.application-navigation[open]::backdrop {
|
52
|
+
background-color: rgb(0 0 0 / 0%);
|
53
|
+
}
|
54
|
+
}
|
@@ -0,0 +1,90 @@
|
|
1
|
+
.button {
|
2
|
+
/* Configuration */
|
3
|
+
--button-padding: 0.5em 1em;
|
4
|
+
--button-gap: 0.5em;
|
5
|
+
--button-bg: var(--color-dark);
|
6
|
+
--button-color: var(--color-light);
|
7
|
+
--button-hover-bg: var(--color-dark-glare);
|
8
|
+
--button-hover-color: var(--color-light);
|
9
|
+
--button-border-width: 2px;
|
10
|
+
--button-border-style: solid;
|
11
|
+
--button-border-color: var(--button-bg);
|
12
|
+
--button-radius: 0.25em;
|
13
|
+
--button-outline-color: var(--focus-color);
|
14
|
+
|
15
|
+
/* Layout and spacing */
|
16
|
+
display: inline-flex;
|
17
|
+
align-items: baseline;
|
18
|
+
gap: var(--button-gap);
|
19
|
+
padding: var(--button-padding);
|
20
|
+
|
21
|
+
/* Colours */
|
22
|
+
background: var(--button-bg);
|
23
|
+
color: var(--button-color);
|
24
|
+
|
25
|
+
/* Stroke and radius */
|
26
|
+
border-width: var(--button-border-width);
|
27
|
+
border-style: var(--button-border-style);
|
28
|
+
border-color: var(--button-border-color);
|
29
|
+
border-radius: var(--button-radius);
|
30
|
+
|
31
|
+
/* Typography */
|
32
|
+
text-decoration: none;
|
33
|
+
font-weight: var(--button-font-weight, 500);
|
34
|
+
font-size: var(--button-font-size, 1em);
|
35
|
+
letter-spacing: 0.05ch;
|
36
|
+
font-family: var(--font-base);
|
37
|
+
line-height: 1.1;
|
38
|
+
|
39
|
+
/* Interactive */
|
40
|
+
cursor: pointer;
|
41
|
+
|
42
|
+
transition:
|
43
|
+
color 0.2s ease,
|
44
|
+
background 0.2s ease,
|
45
|
+
border-color 0.2s ease;
|
46
|
+
|
47
|
+
&:hover {
|
48
|
+
background: var(--button-hover-bg);
|
49
|
+
color: var(--button-hover-color);
|
50
|
+
}
|
51
|
+
|
52
|
+
&:focus-visible {
|
53
|
+
outline: var(--button-outline-color, var(--button-border-color))
|
54
|
+
var(--button-outline-style, var(--button-border-style))
|
55
|
+
var(--button-outline-width, var(--button-border-width));
|
56
|
+
outline-offset: var(
|
57
|
+
--button-outline-offset,
|
58
|
+
calc(var(--button-border-width))
|
59
|
+
);
|
60
|
+
}
|
61
|
+
|
62
|
+
&:active {
|
63
|
+
transform: scale(99%);
|
64
|
+
}
|
65
|
+
|
66
|
+
&[disabled] {
|
67
|
+
opacity: 0.45;
|
68
|
+
pointer-events: none;
|
69
|
+
}
|
70
|
+
|
71
|
+
&[data-button-padding="tight"] {
|
72
|
+
--button-padding: 0.5em;
|
73
|
+
}
|
74
|
+
|
75
|
+
&[data-ghost-button] {
|
76
|
+
--button-bg: transparent;
|
77
|
+
--button-border-color: currentColor;
|
78
|
+
--button-color: currentColor;
|
79
|
+
}
|
80
|
+
|
81
|
+
&[data-button-radius="hard"] {
|
82
|
+
--button-radius: 0;
|
83
|
+
}
|
84
|
+
|
85
|
+
&[data-text-button] {
|
86
|
+
--button-bg: transparent;
|
87
|
+
--button-border-color: transparent;
|
88
|
+
--button-color: currentColor;
|
89
|
+
}
|
90
|
+
}
|
@@ -0,0 +1,19 @@
|
|
1
|
+
.flash {
|
2
|
+
color: var(--flash-color);
|
3
|
+
}
|
4
|
+
|
5
|
+
.flash:is([data-flash-type="alert"]) {
|
6
|
+
--flash-color: var(--color-alert);
|
7
|
+
}
|
8
|
+
|
9
|
+
.flash:is([data-flash-type="notice"]) {
|
10
|
+
--flash-color: var(--color-notice);
|
11
|
+
}
|
12
|
+
|
13
|
+
.flash:is([data-flash-type="success"]) {
|
14
|
+
--flash-color: var(--color-success);
|
15
|
+
}
|
16
|
+
|
17
|
+
.flash:is([data-flash-type="warning"], [data-flash-type="error"]) {
|
18
|
+
--flash-color: var(--color-warning);
|
19
|
+
}
|
@@ -0,0 +1,15 @@
|
|
1
|
+
.icon {
|
2
|
+
--scale: 1;
|
3
|
+
--size: 1em;
|
4
|
+
aspect-ratio: 1;
|
5
|
+
background-color: currentColor;
|
6
|
+
display: inline-block;
|
7
|
+
font-size: calc(var(--scale) * var(--size));
|
8
|
+
height: 1em;
|
9
|
+
line-height: 1em;
|
10
|
+
transform: translateY(var(--offset, 0));
|
11
|
+
-webkit-mask-repeat: no-repeat;
|
12
|
+
mask-repeat: no-repeat;
|
13
|
+
-webkit-mask-position: center;
|
14
|
+
mask-position: center;
|
15
|
+
}
|
@@ -0,0 +1,13 @@
|
|
1
|
+
@import url("actions.css");
|
2
|
+
@import url("application-header.css");
|
3
|
+
@import url("application-navigation.css");
|
4
|
+
@import url("button.css");
|
5
|
+
@import url("flash.css");
|
6
|
+
@import url("icon.css");
|
7
|
+
@import url("modal.css");
|
8
|
+
@import url("navigation.css");
|
9
|
+
@import url("page-header.css");
|
10
|
+
@import url("pagy.css");
|
11
|
+
@import url("prose.css");
|
12
|
+
@import url("tables/index.css");
|
13
|
+
@import url("toolbar.css");
|
@@ -0,0 +1,26 @@
|
|
1
|
+
.modal {
|
2
|
+
--modal-gutter: var(--space-s);
|
3
|
+
--modal-width: 80%;
|
4
|
+
--modal-max-width: 36rem;
|
5
|
+
--modal-max-height: 27rem;
|
6
|
+
--modal-padding: var(--space-s);
|
7
|
+
|
8
|
+
container-type: inline-size;
|
9
|
+
padding: 0;
|
10
|
+
width: var(--modal-width);
|
11
|
+
|
12
|
+
max-width: min(
|
13
|
+
calc(100svw - 2 * var(--modal-gutter)),
|
14
|
+
var(--modal-max-width)
|
15
|
+
);
|
16
|
+
|
17
|
+
max-height: calc(100svh - 2 * var(--modal-gutter));
|
18
|
+
|
19
|
+
> * {
|
20
|
+
padding: var(--modal-padding);
|
21
|
+
}
|
22
|
+
}
|
23
|
+
|
24
|
+
.modal::backdrop {
|
25
|
+
background-color: rgba(0, 0, 0, 0.6);
|
26
|
+
}
|
@@ -0,0 +1,23 @@
|
|
1
|
+
.navigation-group > li > span:first-child {
|
2
|
+
font-size: var(--size-step-2);
|
3
|
+
font-weight: var(--font-bold);
|
4
|
+
}
|
5
|
+
|
6
|
+
.navigation-group > li > * + * {
|
7
|
+
margin-block-start: var(--space-2xs);
|
8
|
+
--flow-space: var(--space-xs);
|
9
|
+
}
|
10
|
+
|
11
|
+
.navigation-list > li > span:first-child {
|
12
|
+
font-size: var(--size-step-1);
|
13
|
+
font-weight: var(--font-bold);
|
14
|
+
}
|
15
|
+
|
16
|
+
.navigation-list > li > * + * {
|
17
|
+
margin-block-start: var(--space-2xs);
|
18
|
+
--flow-space: var(--space-xs);
|
19
|
+
}
|
20
|
+
|
21
|
+
.navigation-list .navigation-list {
|
22
|
+
padding-inline-start: var(--space-s);
|
23
|
+
}
|
@@ -0,0 +1,31 @@
|
|
1
|
+
.page-header {
|
2
|
+
background: var(--color-tint);
|
3
|
+
color: var(--color-dark);
|
4
|
+
|
5
|
+
> .wrapper {
|
6
|
+
padding-block: var(--gutter);
|
7
|
+
}
|
8
|
+
|
9
|
+
.breadcrumbs-list,
|
10
|
+
.actions-list {
|
11
|
+
display: flex;
|
12
|
+
gap: 0;
|
13
|
+
align-items: baseline;
|
14
|
+
}
|
15
|
+
|
16
|
+
.breadcrumbs-list > * + * {
|
17
|
+
list-style-type: "›";
|
18
|
+
margin-inline-start: 1.5ch;
|
19
|
+
padding-inline-start: 0.75ch;
|
20
|
+
}
|
21
|
+
|
22
|
+
.actions-list > * + * {
|
23
|
+
list-style-type: "▪";
|
24
|
+
margin-inline-start: 1.5ch;
|
25
|
+
padding-inline-start: 0.5ch;
|
26
|
+
}
|
27
|
+
}
|
28
|
+
|
29
|
+
.page-header + main {
|
30
|
+
padding-top: var(--gutter);
|
31
|
+
}
|
@@ -0,0 +1,82 @@
|
|
1
|
+
.pagy.nav {
|
2
|
+
/* Configuration */
|
3
|
+
--button-padding: 0.5em 1em;
|
4
|
+
--button-gap: 0.5em;
|
5
|
+
--button-bg: transparent;
|
6
|
+
--button-color: currentColor;
|
7
|
+
--button-hover-bg: var(--color-dark-glare);
|
8
|
+
--button-hover-color: var(--color-light);
|
9
|
+
--button-border-width: 2px;
|
10
|
+
--button-border-style: solid;
|
11
|
+
--button-border-color: var(--button-bg);
|
12
|
+
--button-radius: 0.25em;
|
13
|
+
--button-outline-color: var(--focus-color);
|
14
|
+
|
15
|
+
display: flex;
|
16
|
+
gap: var(--space-2xs);
|
17
|
+
|
18
|
+
a {
|
19
|
+
/* Layout and spacing */
|
20
|
+
display: inline-flex;
|
21
|
+
align-items: baseline;
|
22
|
+
gap: var(--button-gap);
|
23
|
+
padding: var(--button-padding);
|
24
|
+
|
25
|
+
/* Colours */
|
26
|
+
background: var(--button-bg);
|
27
|
+
color: var(--button-color);
|
28
|
+
|
29
|
+
/* Stroke and radius */
|
30
|
+
border-width: var(--button-border-width);
|
31
|
+
border-style: var(--button-border-style);
|
32
|
+
border-color: var(--button-border-color);
|
33
|
+
border-radius: var(--button-radius);
|
34
|
+
|
35
|
+
/* Typography */
|
36
|
+
text-decoration: none;
|
37
|
+
font-weight: var(--button-font-weight, 500);
|
38
|
+
font-size: var(--button-font-size, 1em);
|
39
|
+
letter-spacing: 0.05ch;
|
40
|
+
font-family: sans-serif;
|
41
|
+
line-height: 1.1;
|
42
|
+
|
43
|
+
/* Interactive */
|
44
|
+
cursor: pointer;
|
45
|
+
|
46
|
+
transition:
|
47
|
+
color 0.2s ease,
|
48
|
+
background 0.2s ease,
|
49
|
+
border-color 0.2s ease;
|
50
|
+
|
51
|
+
&:hover {
|
52
|
+
background: var(--button-hover-bg);
|
53
|
+
color: var(--button-hover-color);
|
54
|
+
}
|
55
|
+
|
56
|
+
&:focus-visible {
|
57
|
+
outline: var(--button-outline-color, var(--button-border-color))
|
58
|
+
var(--button-outline-style, var(--button-border-style))
|
59
|
+
var(--button-outline-width, var(--button-border-width));
|
60
|
+
outline-offset: var(
|
61
|
+
--button-outline-offset,
|
62
|
+
calc(var(--button-border-width))
|
63
|
+
);
|
64
|
+
}
|
65
|
+
|
66
|
+
&:active {
|
67
|
+
transform: scale(99%);
|
68
|
+
}
|
69
|
+
|
70
|
+
&[aria-disabled] {
|
71
|
+
--button-border-color: transparent;
|
72
|
+
opacity: 0.45;
|
73
|
+
pointer-events: none;
|
74
|
+
}
|
75
|
+
|
76
|
+
&[aria-current] {
|
77
|
+
--button-border-color: currentColor;
|
78
|
+
opacity: 1;
|
79
|
+
pointer-events: none;
|
80
|
+
}
|
81
|
+
}
|
82
|
+
}
|
@@ -0,0 +1,37 @@
|
|
1
|
+
.prose {
|
2
|
+
--flow-space: var(--space-l);
|
3
|
+
}
|
4
|
+
|
5
|
+
.prose :is(h1, h2, h3) {
|
6
|
+
overflow-wrap: anywhere;
|
7
|
+
hyphens: auto;
|
8
|
+
}
|
9
|
+
|
10
|
+
.prose :is(p, li, dl, figcaption, blockquote) {
|
11
|
+
max-width: 60ch;
|
12
|
+
text-wrap: pretty;
|
13
|
+
}
|
14
|
+
|
15
|
+
.prose :is(h1, h2, h3, h4) + *:not([class]) {
|
16
|
+
--flow-space: var(--space-m);
|
17
|
+
}
|
18
|
+
|
19
|
+
/* Add more space on and around figures and tables */
|
20
|
+
.prose :is(figure, table),
|
21
|
+
.prose :is(figure, table) + * {
|
22
|
+
--flow-space: var(--space-2xl);
|
23
|
+
}
|
24
|
+
|
25
|
+
/* Add more space to headings on block start */
|
26
|
+
.prose * + :is(h1, h2, h3, h4):not([class]) {
|
27
|
+
--flow-space: var(--space-xl);
|
28
|
+
}
|
29
|
+
|
30
|
+
.prose :is(ul, ol):not([class]) li + li,
|
31
|
+
.prose :is(ul, ol):not([class]) li > :is(ol, ul) {
|
32
|
+
--flow-space: var(--space-xs);
|
33
|
+
}
|
34
|
+
|
35
|
+
.prose hr {
|
36
|
+
--flow-space: var(--space-2xl);
|
37
|
+
}
|
@@ -1,10 +1,4 @@
|
|
1
|
-
|
2
|
-
@use "sass:string";
|
3
|
-
@use "../utils/typography";
|
4
|
-
|
5
|
-
$text-icon-color: #888;
|
6
|
-
|
7
|
-
[data-controller="tables--query"] {
|
1
|
+
.katalyst--tables--query {
|
8
2
|
display: flex;
|
9
3
|
flex-grow: 1;
|
10
4
|
max-width: var(--text-width);
|
@@ -22,9 +16,12 @@ $text-icon-color: #888;
|
|
22
16
|
outline: none;
|
23
17
|
border-width: 2px;
|
24
18
|
padding: 5px 2rem 5px 5px;
|
19
|
+
font-size: var(--size-step-0);
|
20
|
+
line-height: var(--leading-standard);
|
25
21
|
}
|
26
22
|
|
27
23
|
button[type="submit"] {
|
24
|
+
display: block;
|
28
25
|
position: absolute;
|
29
26
|
appearance: none;
|
30
27
|
top: 6px;
|
@@ -34,14 +31,16 @@ $text-icon-color: #888;
|
|
34
31
|
min-width: 1.5rem;
|
35
32
|
text-align: center;
|
36
33
|
font-size: 0;
|
34
|
+
font-size-adjust: none;
|
37
35
|
background: none;
|
38
36
|
padding: 0;
|
39
37
|
line-height: 1;
|
40
38
|
border-radius: 4px;
|
41
39
|
border: 1px solid #aaa;
|
42
|
-
color:
|
40
|
+
color: var(--color-mid);
|
41
|
+
|
42
|
+
/* shows keyboard shortcut when not active */
|
43
43
|
|
44
|
-
// shows keyboard shortcut when not active
|
45
44
|
&::before {
|
46
45
|
display: block;
|
47
46
|
content: "/";
|
@@ -53,7 +52,8 @@ $text-icon-color: #888;
|
|
53
52
|
button[type="submit"]:focus {
|
54
53
|
opacity: 1;
|
55
54
|
|
56
|
-
|
55
|
+
/* submittable */
|
56
|
+
|
57
57
|
&::before {
|
58
58
|
content: "⏎";
|
59
59
|
position: relative;
|
@@ -62,7 +62,7 @@ $text-icon-color: #888;
|
|
62
62
|
}
|
63
63
|
|
64
64
|
h4 {
|
65
|
-
font-size:
|
65
|
+
font-size: var(--size-step-0);
|
66
66
|
font-weight: 500;
|
67
67
|
line-height: 1.5;
|
68
68
|
color: #666;
|
@@ -99,10 +99,10 @@ $text-icon-color: #888;
|
|
99
99
|
|
100
100
|
li.suggestion.attribute::after {
|
101
101
|
content: ":";
|
102
|
-
color:
|
102
|
+
color: var(--color-mid);
|
103
103
|
}
|
104
104
|
|
105
105
|
footer {
|
106
|
-
font-size:
|
106
|
+
font-size: var(--size-step--1);
|
107
107
|
}
|
108
108
|
}
|