katalyst-koi 4.5.0.beta.2 → 4.5.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (37) hide show
  1. checksums.yaml +4 -4
  2. data/app/assets/builds/koi/admin.css +201 -108
  3. data/app/assets/builds/koi/admin.css.map +1 -1
  4. data/app/assets/javascripts/koi/controllers/clipboard_controller.js +23 -0
  5. data/app/assets/stylesheets/koi/components/_clipboard.scss +46 -0
  6. data/app/assets/stylesheets/koi/components/_index-table.scss +54 -3
  7. data/app/assets/stylesheets/koi/components/_index.scss +1 -0
  8. data/app/assets/stylesheets/koi/layouts/_navigation.scss +0 -1
  9. data/app/assets/stylesheets/koi/pages/_login.scss +6 -0
  10. data/app/assets/stylesheets/koi/themes/_content.scss +38 -0
  11. data/app/components/koi/content/editor/item_form_component.html.erb +1 -1
  12. data/app/components/koi/content/editor/item_form_component.rb +4 -2
  13. data/app/components/koi/summary_list/attachment_component.rb +11 -1
  14. data/app/components/koi/summary_list_component.rb +2 -2
  15. data/app/components/koi/tables/body.rb +116 -27
  16. data/app/components/koi/tables/body_row_component.rb +116 -18
  17. data/app/components/koi/tables/header.rb +51 -1
  18. data/app/components/koi/tables/header_cell_component.rb +30 -0
  19. data/app/components/koi/tables/header_row_component.rb +182 -20
  20. data/app/controllers/admin/tokens_controller.rb +60 -0
  21. data/app/controllers/concerns/koi/controller/json_web_token.rb +22 -0
  22. data/app/helpers/koi/date_helper.rb +18 -28
  23. data/app/models/admin/user.rb +2 -1
  24. data/app/views/admin/admin_users/show.html.erb +7 -6
  25. data/app/views/admin/sessions/new.html.erb +9 -0
  26. data/app/views/admin/tokens/create.turbo_stream.erb +9 -0
  27. data/app/views/admin/tokens/show.html.erb +13 -0
  28. data/app/views/katalyst/content/tables/_table.html+form.erb +41 -0
  29. data/app/views/layouts/koi/_navigation.html.erb +1 -1
  30. data/app/views/layouts/koi/_navigation_header.html.erb +6 -1
  31. data/config/routes.rb +8 -1
  32. data/lib/generators/koi/admin_controller/templates/controller.rb.tt +6 -7
  33. data/lib/generators/koi/admin_controller/templates/controller_spec.rb.tt +4 -4
  34. data/lib/generators/koi/admin_views/admin_views_generator.rb +6 -4
  35. data/lib/koi/config.rb +3 -0
  36. data/lib/koi/form_builder.rb +2 -2
  37. metadata +11 -4
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 497ea633277bb4a1cfce2ca7a6851fd66babb12e8e17f4b9d5dd4d6e83e1a0a8
4
- data.tar.gz: ffd4e226563a874a8125516405ce5af36b6e0676929b2b0d13f9fb7fd1b9b041
3
+ metadata.gz: 3debdf70dd6f69a2e6a42147cd502b1f57146c7940669b32f8a1719fc4841357
4
+ data.tar.gz: 171adc3e86cf8fa2e16cdfceeada0d6893f0841a82dafac9f69f64b738dcd0c4
5
5
  SHA512:
6
- metadata.gz: e87879149a655700897d8b7ea54d69eb0a883a4371cbdf24e0faba387e4fc64c047add5ea0935172368811a8ef8384bc1451c213d48208d8a70888f7bf102ac9
7
- data.tar.gz: 4d14f1a670a87852fb48b0127ecf4f8c1a0987cb2e3917deef81951993e5f86b919aa8ccdc78ae0833d60fbe24d20ffa9a3eb12046f3398e855abb7a7145e6cf
6
+ metadata.gz: e34a31d33b62cb0eda69e800a8550c6ad5822e1235d7e84eb31b868214cf9ca385b0241f01fb6d21eec8cb3d4f1c1fc94d4e188cb89ecdc934b07bc7deee1797
7
+ data.tar.gz: 63244aa467830110994f070c7d702db0882fd4eec10205c1e4c85fd7578df3876056d8a64c33a7465f0c01e101f4bccc350f66fda2e0fb842b4f465cd085c06f
@@ -307,6 +307,47 @@ textarea {
307
307
  column-gap: 0.5rem;
308
308
  }
309
309
 
310
+ .copy-to-clipboard {
311
+ position: relative;
312
+ }
313
+ .copy-to-clipboard .copy-to-clipboard-feedback {
314
+ animation: ease-in-out 0.5s;
315
+ display: none;
316
+ position: absolute;
317
+ top: 0;
318
+ right: 0;
319
+ left: 0;
320
+ margin-top: -1em;
321
+ z-index: 10;
322
+ white-space: nowrap;
323
+ text-align: center;
324
+ }
325
+ .copy-to-clipboard .copy-to-clipboard-feedback:after {
326
+ content: "Link copied to your clipboard!";
327
+ display: inline-block;
328
+ padding: 0.33em 1em 0.33em 1em;
329
+ border-radius: 3rem;
330
+ color: white;
331
+ background-color: black;
332
+ }
333
+ .copy-to-clipboard.copied .copy-to-clipboard-feedback {
334
+ display: block;
335
+ }
336
+ .copy-to-clipboard .clipboard-button {
337
+ display: none;
338
+ }
339
+ .copy-to-clipboard.clipboard--supported .clipboard-button {
340
+ display: initial;
341
+ }
342
+
343
+ .actions .action.copy-to-clipboard {
344
+ display: flex;
345
+ flex: auto;
346
+ }
347
+ .actions .action.copy-to-clipboard input[type=text] {
348
+ flex: auto;
349
+ }
350
+
310
351
  .govuk-document-field {
311
352
  display: grid;
312
353
  grid-template-areas: "label" "hint" "error" "preview" "file" "supplemental";
@@ -540,8 +581,12 @@ textarea {
540
581
 
541
582
  .index-table {
542
583
  --row-height: 48px;
584
+ --cell-spacing: 0.5rem;
543
585
  --table-header-color: transparent;
544
586
  --row-border-color: #f0ecf3;
587
+ --width-small: 6rem;
588
+ --width-medium: 12rem;
589
+ --width-large: 16rem;
545
590
  }
546
591
 
547
592
  .index-table {
@@ -567,6 +612,11 @@ textarea {
567
612
  vertical-align: top;
568
613
  white-space: nowrap;
569
614
  background-color: white;
615
+ padding-right: var(--cell-spacing);
616
+ }
617
+ .index-table th:last-child,
618
+ .index-table td:last-child {
619
+ padding-right: 0;
570
620
  }
571
621
  .index-table th > a,
572
622
  .index-table td > a {
@@ -583,14 +633,35 @@ textarea {
583
633
  max-height: 3rem;
584
634
  padding: 0;
585
635
  }
586
- .index-table th.number,
587
- .index-table td.number {
588
- text-align: right;
589
- padding-right: 0.5rem;
636
+ .index-table th > .trix-content,
637
+ .index-table td > .trix-content {
638
+ overflow: hidden;
639
+ text-overflow: ellipsis;
590
640
  }
591
641
  .index-table th {
592
642
  font-weight: bold;
593
643
  }
644
+ .index-table thead th.type-boolean, .index-table thead th.type-number {
645
+ width: var(--width-small);
646
+ }
647
+ .index-table thead th.type-date, .index-table thead th.type-currency {
648
+ width: var(--width-medium);
649
+ }
650
+ .index-table thead th.type-datetime {
651
+ width: var(--width-large);
652
+ }
653
+ .index-table thead th.width-s {
654
+ width: var(--width-small);
655
+ }
656
+ .index-table thead th.width-m {
657
+ width: var(--width-medium);
658
+ }
659
+ .index-table thead th.width-l {
660
+ width: var(--width-large);
661
+ }
662
+ .index-table td.type-currency, .index-table td.type-number {
663
+ text-align: right;
664
+ }
594
665
  .index-table thead a.ascending:after,
595
666
  .index-table [data-sort=asc] a::after {
596
667
  display: inline-block;
@@ -728,7 +799,6 @@ textarea {
728
799
  .admin-login header .admin-name, body > nav > ul > li > span, body > nav header .admin-name {
729
800
  color: rgba(255, 255, 255, 0.6);
730
801
  font-size: 0.8rem;
731
- text-transform: uppercase;
732
802
  font-weight: 400;
733
803
  margin: 0;
734
804
  }
@@ -1119,6 +1189,11 @@ body > main {
1119
1189
  flex: 1;
1120
1190
  }
1121
1191
 
1192
+ .admin-login .govuk-error-summary {
1193
+ padding: 15px;
1194
+ margin-bottom: 30px;
1195
+ }
1196
+
1122
1197
  [data-controller=content--editor--item] [data-tree-accordion-controls] [role=button],
1123
1198
  [data-controller=content--editor--item] [data-tree-controls] [role=button], [data-controller=content--editor--item] [role=img][value=invisible] {
1124
1199
  display: block;
@@ -1184,6 +1259,9 @@ body > main {
1184
1259
  [data-controller=content--editor--item] [role=img][value=figure]::before {
1185
1260
  background-image: url("data:image/svg+xml,%3Csvg width='16' height='16' viewBox='0 0 64 64' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M8 0H56C60.4183 0 64 3.8205 64 8.53333V55.4667C64 60.1795 60.4183 64 56 64H8C3.58172 64 0 60.1795 0 55.4667V8.53333C0 3.8205 3.58172 0 8 0ZM48.8131 18.4523C48.8131 20.9113 46.9782 22.9045 44.7145 22.9045C42.4507 22.9045 40.6158 20.9113 40.6158 18.4523C40.6158 15.9934 42.4507 14 44.7145 14C46.9782 14 48.8131 15.9934 48.8131 18.4523ZM9.91404 49.8654H33.37L45.2139 50L55.2315 49.8938C56.6969 49.8783 57.5059 48.1335 56.6514 46.8391L46.4012 31.3112C45.6298 30.1427 44.0089 30.1621 43.3268 31.3485L38.8194 39.1885C34.5783 32.1588 29.6634 24.1159 27.1454 20.0031C26.391 18.7709 24.5821 18.7994 23.8591 20.0499L8.25556 47.0321C7.52586 48.2939 8.44576 49.8654 9.91404 49.8654Z' fill='white'/%3E%3C/svg%3E");
1186
1261
  }
1262
+ [data-controller=content--editor--item] [role=img][value=table]::before {
1263
+ background-image: url("data:image/svg+xml,%3Csvg width='16' height='16' viewBox='0 0 64 64' fill='none' stroke='white' xmlns='http://www.w3.org/2000/svg'%3E%3Crect x='6' y='12' width='26' height='44' stroke-width='4' /%3E%3Crect x='32' y='12' width='26' height='44' stroke-width='4' /%3E%3Cline x1='6' y1='34' x2='58' y2='34' stroke-width='4' /%3E%3C/svg%3E%0A");
1264
+ }
1187
1265
  [data-controller=content--editor--item] [role=img][value=section]::before {
1188
1266
  background-image: url("data:image/svg+xml,%3Csvg width='16' height='16' viewBox='0 0 64 64' fill='white' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M61.4263 64H58.8525C57.4799 64 56.2788 62.8021 56.2788 61.4332C56.2788 60.0642 57.4799 58.8663 58.8525 58.8663C58.8525 57.4973 60.0536 56.2995 61.4263 56.2995C62.7989 56.2995 64 57.4973 64 58.8663V61.4332C64 62.8021 62.9705 64 61.4263 64Z'/%3E%3Cpath d='M49.244 64H44.4397C43.067 64 41.866 62.8021 41.866 61.4332C41.866 60.0642 43.067 58.8663 44.4397 58.8663H49.244C50.6166 58.8663 51.8177 60.0642 51.8177 61.4332C51.8177 62.8021 50.6166 64 49.244 64ZM34.4879 64H29.6836C28.311 64 27.1099 62.8021 27.1099 61.4332C27.1099 60.0642 28.311 58.8663 29.6836 58.8663H34.4879C35.8606 58.8663 37.0617 60.0642 37.0617 61.4332C37.0617 62.8021 35.8606 64 34.4879 64ZM19.9035 64H14.9276C13.555 64 12.3539 62.8021 12.3539 61.4332C12.3539 60.0642 13.555 58.8663 14.9276 58.8663H19.7319C21.1046 58.8663 22.3056 60.0642 22.3056 61.4332C22.3056 62.8021 21.2761 64 19.9035 64Z'/%3E%3Cpath d='M5.14745 64H2.57372C1.20106 64 0 62.8021 0 61.4332V58.8663C0 57.4973 1.20106 56.2995 2.57372 56.2995C3.94637 56.2995 5.14745 57.4973 5.14745 58.8663C6.5201 58.8663 7.72117 60.0642 7.72117 61.4332C7.72117 62.8021 6.69168 64 5.14745 64Z'/%3E%3Cpath d='M2.57372 51.6791C1.20106 51.6791 0 50.4813 0 49.1123V44.3209C0 42.9519 1.20106 41.754 2.57372 41.754C3.94637 41.754 5.14745 42.9519 5.14745 44.3209V49.1123C5.14745 50.4813 4.11795 51.6791 2.57372 51.6791ZM2.57372 36.9626C1.20106 36.9626 0 35.7647 0 34.3957V29.6043C0 28.2353 1.20106 27.0375 2.57372 27.0375C3.94637 27.0375 5.14745 28.2353 5.14745 29.6043V34.3957C5.14745 35.9358 4.11795 36.9626 2.57372 36.9626ZM2.57372 22.4171C1.20106 22.4171 0 21.2193 0 19.8503V14.8877C0 13.5187 1.20106 12.3209 2.57372 12.3209C3.94637 12.3209 5.14745 13.5187 5.14745 14.8877V19.6792C5.14745 21.2193 4.11795 22.4171 2.57372 22.4171Z'/%3E%3Cpath d='M2.57372 7.70053C1.20106 7.70053 0 6.50267 0 5.13369V2.56684C0 1.19786 1.20106 0 2.57372 0H5.14745C6.5201 0 7.72117 1.19786 7.72117 2.56684C7.72117 3.93582 6.5201 5.13369 5.14745 5.13369C5.14745 6.67379 4.11795 7.70053 2.57372 7.70053Z'/%3E%3Cpath d='M49.244 5.13369H44.4397C43.067 5.13369 41.866 3.93583 41.866 2.56684C41.866 1.19786 43.067 0 44.4397 0H49.244C50.6166 0 51.8177 1.19786 51.8177 2.56684C51.8177 3.93583 50.6166 5.13369 49.244 5.13369ZM34.4879 5.13369H29.6836C28.311 5.13369 27.1099 3.93583 27.1099 2.56684C27.1099 1.19786 28.311 0 29.6836 0H34.4879C35.8606 0 37.0617 1.19786 37.0617 2.56684C37.0617 3.93583 35.8606 5.13369 34.4879 5.13369ZM19.9035 5.13369H14.9276C13.555 5.13369 12.3539 3.93583 12.3539 2.56684C12.3539 1.19786 13.555 0 14.9276 0H19.7319C21.1046 0 22.3056 1.19786 22.3056 2.56684C22.3056 3.93583 21.2761 5.13369 19.9035 5.13369Z'/%3E%3Cpath d='M61.4263 7.70053C60.0536 7.70053 58.8525 6.50267 58.8525 5.13369C57.4799 5.13369 56.2788 3.93582 56.2788 2.56684C56.2788 1.19786 57.4799 0 58.8525 0H61.4263C62.7989 0 64 1.19786 64 2.56684V5.13369C64 6.67379 62.9705 7.70053 61.4263 7.70053Z'/%3E%3Cpath d='M61.4263 51.6791C60.0536 51.6791 58.8525 50.4813 58.8525 49.1123V44.3209C58.8525 42.9519 60.0536 41.754 61.4263 41.754C62.7989 41.754 64 42.9519 64 44.3209V49.1123C64 50.4813 62.9705 51.6791 61.4263 51.6791ZM61.4263 36.9626C60.0536 36.9626 58.8525 35.7647 58.8525 34.3957V29.6043C58.8525 28.2353 60.0536 27.0375 61.4263 27.0375C62.7989 27.0375 64 28.2353 64 29.6043V34.3957C64 35.9358 62.9705 36.9626 61.4263 36.9626ZM61.4263 22.4171C60.0536 22.4171 58.8525 21.2193 58.8525 19.8503V14.8877C58.8525 13.5187 60.0536 12.3209 61.4263 12.3209C62.7989 12.3209 64 13.5187 64 14.8877V19.6792C64 21.2193 62.9705 22.4171 61.4263 22.4171Z'/%3E%3Cpath d='M35.5982 38.4425C35.5982 37.7506 35.4524 37.1641 35.1609 36.6828C34.8693 36.2015 34.3465 35.7654 33.5925 35.3743C32.8385 34.9833 31.7678 34.5872 30.3804 34.1861C29.2946 33.8753 28.3143 33.5244 27.4397 33.1333C26.5751 32.7323 25.8311 32.2761 25.2078 31.7647C24.5845 31.2533 24.1069 30.6668 23.7751 30.005C23.4434 29.3432 23.2775 28.5862 23.2775 27.7339C23.2775 26.5909 23.5841 25.5732 24.1974 24.6808C24.8207 23.7784 25.6904 23.0715 26.8063 22.5601C27.9223 22.0388 29.2292 21.7781 30.7272 21.7781C32.3861 21.7781 33.7936 22.0939 34.9497 22.7256C36.1059 23.3472 36.9856 24.1644 37.5888 25.1771C38.192 26.1798 38.4936 27.2527 38.4936 28.3957H35.553C35.553 27.5735 35.377 26.8416 35.0251 26.1999C34.6833 25.5581 34.1555 25.0568 33.4417 24.6958C32.7279 24.3249 31.8231 24.1394 30.7272 24.1394C29.7017 24.1394 28.8522 24.2948 28.1786 24.6056C27.5151 24.9164 27.0225 25.3376 26.7007 25.869C26.379 26.4004 26.2182 27.007 26.2182 27.6888C26.2182 28.3005 26.3941 28.8469 26.746 29.3282C27.0979 29.7994 27.6508 30.2256 28.4048 30.6066C29.1589 30.9876 30.1341 31.3486 31.3304 31.6895C32.9893 32.1507 34.3515 32.6871 35.4172 33.2988C36.4829 33.9104 37.2671 34.6323 37.7698 35.4646C38.2825 36.2968 38.5389 37.2794 38.5389 38.4124C38.5389 39.5956 38.2222 40.6283 37.5888 41.5107C36.9554 42.393 36.0657 43.0748 34.9196 43.5561C33.7735 44.0374 32.4263 44.278 30.878 44.278C29.8626 44.278 28.8623 44.1377 27.877 43.8569C26.9018 43.5762 26.0121 43.1551 25.2078 42.5936C24.4135 42.0321 23.7751 41.3402 23.2926 40.518C22.82 39.6858 22.5838 38.7232 22.5838 37.6303H25.5094C25.5094 38.3823 25.6552 39.0291 25.9467 39.5705C26.2383 40.1119 26.6354 40.5581 27.1381 40.9091C27.6408 41.26 28.2138 41.5207 28.8572 41.6912C29.5007 41.8516 30.1743 41.9318 30.878 41.9318C31.8934 41.9318 32.748 41.7914 33.4417 41.5107C34.1454 41.2199 34.6783 40.8138 35.0402 40.2924C35.4122 39.771 35.5982 39.1544 35.5982 38.4425Z'/%3E%3C/svg%3E%0A");
1189
1267
  }
@@ -1273,6 +1351,9 @@ body > main {
1273
1351
  .content--editor--new-items [role=listitem][data-item-type=figure]:before {
1274
1352
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 64 64' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M8 0H56C60.4183 0 64 3.8205 64 8.53333V55.4667C64 60.1795 60.4183 64 56 64H8C3.58172 64 0 60.1795 0 55.4667V8.53333C0 3.8205 3.58172 0 8 0ZM48.8131 18.4523C48.8131 20.9113 46.9782 22.9045 44.7145 22.9045C42.4507 22.9045 40.6158 20.9113 40.6158 18.4523C40.6158 15.9934 42.4507 14 44.7145 14C46.9782 14 48.8131 15.9934 48.8131 18.4523ZM9.91404 49.8654H33.37L45.2139 50L55.2315 49.8938C56.6969 49.8783 57.5059 48.1335 56.6514 46.8391L46.4012 31.3112C45.6298 30.1427 44.0089 30.1621 43.3268 31.3485L38.8194 39.1885C34.5783 32.1588 29.6634 24.1159 27.1454 20.0031C26.391 18.7709 24.5821 18.7994 23.8591 20.0499L8.25556 47.0321C7.52586 48.2939 8.44576 49.8654 9.91404 49.8654Z' fill='black'/%3E%3C/svg%3E");
1275
1353
  }
1354
+ .content--editor--new-items [role=listitem][data-item-type=table]:before {
1355
+ background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 64 64' fill='none' stroke='black' xmlns='http://www.w3.org/2000/svg'%3E%3Crect x='6' y='12' width='26' height='44' stroke-width='4' /%3E%3Crect x='32' y='12' width='26' height='44' stroke-width='4' /%3E%3Cline x1='6' y1='34' x2='58' y2='34' stroke-width='4' /%3E%3C/svg%3E%0A");
1356
+ }
1276
1357
  .content--editor--new-items [role=listitem][data-item-type=section]:before {
1277
1358
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 64 64' fill='black' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M61.4263 64H58.8525C57.4799 64 56.2788 62.8021 56.2788 61.4332C56.2788 60.0642 57.4799 58.8663 58.8525 58.8663C58.8525 57.4973 60.0536 56.2995 61.4263 56.2995C62.7989 56.2995 64 57.4973 64 58.8663V61.4332C64 62.8021 62.9705 64 61.4263 64Z'/%3E%3Cpath d='M49.244 64H44.4397C43.067 64 41.866 62.8021 41.866 61.4332C41.866 60.0642 43.067 58.8663 44.4397 58.8663H49.244C50.6166 58.8663 51.8177 60.0642 51.8177 61.4332C51.8177 62.8021 50.6166 64 49.244 64ZM34.4879 64H29.6836C28.311 64 27.1099 62.8021 27.1099 61.4332C27.1099 60.0642 28.311 58.8663 29.6836 58.8663H34.4879C35.8606 58.8663 37.0617 60.0642 37.0617 61.4332C37.0617 62.8021 35.8606 64 34.4879 64ZM19.9035 64H14.9276C13.555 64 12.3539 62.8021 12.3539 61.4332C12.3539 60.0642 13.555 58.8663 14.9276 58.8663H19.7319C21.1046 58.8663 22.3056 60.0642 22.3056 61.4332C22.3056 62.8021 21.2761 64 19.9035 64Z'/%3E%3Cpath d='M5.14745 64H2.57372C1.20106 64 0 62.8021 0 61.4332V58.8663C0 57.4973 1.20106 56.2995 2.57372 56.2995C3.94637 56.2995 5.14745 57.4973 5.14745 58.8663C6.5201 58.8663 7.72117 60.0642 7.72117 61.4332C7.72117 62.8021 6.69168 64 5.14745 64Z'/%3E%3Cpath d='M2.57372 51.6791C1.20106 51.6791 0 50.4813 0 49.1123V44.3209C0 42.9519 1.20106 41.754 2.57372 41.754C3.94637 41.754 5.14745 42.9519 5.14745 44.3209V49.1123C5.14745 50.4813 4.11795 51.6791 2.57372 51.6791ZM2.57372 36.9626C1.20106 36.9626 0 35.7647 0 34.3957V29.6043C0 28.2353 1.20106 27.0375 2.57372 27.0375C3.94637 27.0375 5.14745 28.2353 5.14745 29.6043V34.3957C5.14745 35.9358 4.11795 36.9626 2.57372 36.9626ZM2.57372 22.4171C1.20106 22.4171 0 21.2193 0 19.8503V14.8877C0 13.5187 1.20106 12.3209 2.57372 12.3209C3.94637 12.3209 5.14745 13.5187 5.14745 14.8877V19.6792C5.14745 21.2193 4.11795 22.4171 2.57372 22.4171Z'/%3E%3Cpath d='M2.57372 7.70053C1.20106 7.70053 0 6.50267 0 5.13369V2.56684C0 1.19786 1.20106 0 2.57372 0H5.14745C6.5201 0 7.72117 1.19786 7.72117 2.56684C7.72117 3.93582 6.5201 5.13369 5.14745 5.13369C5.14745 6.67379 4.11795 7.70053 2.57372 7.70053Z'/%3E%3Cpath d='M49.244 5.13369H44.4397C43.067 5.13369 41.866 3.93583 41.866 2.56684C41.866 1.19786 43.067 0 44.4397 0H49.244C50.6166 0 51.8177 1.19786 51.8177 2.56684C51.8177 3.93583 50.6166 5.13369 49.244 5.13369ZM34.4879 5.13369H29.6836C28.311 5.13369 27.1099 3.93583 27.1099 2.56684C27.1099 1.19786 28.311 0 29.6836 0H34.4879C35.8606 0 37.0617 1.19786 37.0617 2.56684C37.0617 3.93583 35.8606 5.13369 34.4879 5.13369ZM19.9035 5.13369H14.9276C13.555 5.13369 12.3539 3.93583 12.3539 2.56684C12.3539 1.19786 13.555 0 14.9276 0H19.7319C21.1046 0 22.3056 1.19786 22.3056 2.56684C22.3056 3.93583 21.2761 5.13369 19.9035 5.13369Z'/%3E%3Cpath d='M61.4263 7.70053C60.0536 7.70053 58.8525 6.50267 58.8525 5.13369C57.4799 5.13369 56.2788 3.93582 56.2788 2.56684C56.2788 1.19786 57.4799 0 58.8525 0H61.4263C62.7989 0 64 1.19786 64 2.56684V5.13369C64 6.67379 62.9705 7.70053 61.4263 7.70053Z'/%3E%3Cpath d='M61.4263 51.6791C60.0536 51.6791 58.8525 50.4813 58.8525 49.1123V44.3209C58.8525 42.9519 60.0536 41.754 61.4263 41.754C62.7989 41.754 64 42.9519 64 44.3209V49.1123C64 50.4813 62.9705 51.6791 61.4263 51.6791ZM61.4263 36.9626C60.0536 36.9626 58.8525 35.7647 58.8525 34.3957V29.6043C58.8525 28.2353 60.0536 27.0375 61.4263 27.0375C62.7989 27.0375 64 28.2353 64 29.6043V34.3957C64 35.9358 62.9705 36.9626 61.4263 36.9626ZM61.4263 22.4171C60.0536 22.4171 58.8525 21.2193 58.8525 19.8503V14.8877C58.8525 13.5187 60.0536 12.3209 61.4263 12.3209C62.7989 12.3209 64 13.5187 64 14.8877V19.6792C64 21.2193 62.9705 22.4171 61.4263 22.4171Z'/%3E%3Cpath d='M35.5982 38.4425C35.5982 37.7506 35.4524 37.1641 35.1609 36.6828C34.8693 36.2015 34.3465 35.7654 33.5925 35.3743C32.8385 34.9833 31.7678 34.5872 30.3804 34.1861C29.2946 33.8753 28.3143 33.5244 27.4397 33.1333C26.5751 32.7323 25.8311 32.2761 25.2078 31.7647C24.5845 31.2533 24.1069 30.6668 23.7751 30.005C23.4434 29.3432 23.2775 28.5862 23.2775 27.7339C23.2775 26.5909 23.5841 25.5732 24.1974 24.6808C24.8207 23.7784 25.6904 23.0715 26.8063 22.5601C27.9223 22.0388 29.2292 21.7781 30.7272 21.7781C32.3861 21.7781 33.7936 22.0939 34.9497 22.7256C36.1059 23.3472 36.9856 24.1644 37.5888 25.1771C38.192 26.1798 38.4936 27.2527 38.4936 28.3957H35.553C35.553 27.5735 35.377 26.8416 35.0251 26.1999C34.6833 25.5581 34.1555 25.0568 33.4417 24.6958C32.7279 24.3249 31.8231 24.1394 30.7272 24.1394C29.7017 24.1394 28.8522 24.2948 28.1786 24.6056C27.5151 24.9164 27.0225 25.3376 26.7007 25.869C26.379 26.4004 26.2182 27.007 26.2182 27.6888C26.2182 28.3005 26.3941 28.8469 26.746 29.3282C27.0979 29.7994 27.6508 30.2256 28.4048 30.6066C29.1589 30.9876 30.1341 31.3486 31.3304 31.6895C32.9893 32.1507 34.3515 32.6871 35.4172 33.2988C36.4829 33.9104 37.2671 34.6323 37.7698 35.4646C38.2825 36.2968 38.5389 37.2794 38.5389 38.4124C38.5389 39.5956 38.2222 40.6283 37.5888 41.5107C36.9554 42.393 36.0657 43.0748 34.9196 43.5561C33.7735 44.0374 32.4263 44.278 30.878 44.278C29.8626 44.278 28.8623 44.1377 27.877 43.8569C26.9018 43.5762 26.0121 43.1551 25.2078 42.5936C24.4135 42.0321 23.7751 41.3402 23.2926 40.518C22.82 39.6858 22.5838 38.7232 22.5838 37.6303H25.5094C25.5094 38.3823 25.6552 39.0291 25.9467 39.5705C26.2383 40.1119 26.6354 40.5581 27.1381 40.9091C27.6408 41.26 28.2138 41.5207 28.8572 41.6912C29.5007 41.8516 30.1743 41.9318 30.878 41.9318C31.8934 41.9318 32.748 41.7914 33.4417 41.5107C34.1454 41.2199 34.6783 40.8138 35.0402 40.2924C35.4122 39.771 35.5982 39.1544 35.5982 38.4425Z'/%3E%3C/svg%3E%0A");
1278
1359
  }
@@ -1371,6 +1452,41 @@ body > main {
1371
1452
  display: none;
1372
1453
  }
1373
1454
 
1455
+ [data-content--editor--table-target=content] {
1456
+ position: relative;
1457
+ min-height: 8rem;
1458
+ }
1459
+ [data-content--editor--table-target=content]::after {
1460
+ content: "Paste table here";
1461
+ display: block;
1462
+ position: absolute;
1463
+ top: 50%;
1464
+ left: 50%;
1465
+ transform: translate(-50%, -50%);
1466
+ opacity: 0.5;
1467
+ }
1468
+ [data-content--editor--table-target=content]:has(table)::after {
1469
+ content: unset;
1470
+ }
1471
+ [data-content--editor--table-target=content] table {
1472
+ border-collapse: collapse;
1473
+ max-width: 100%;
1474
+ overflow: hidden;
1475
+ }
1476
+ [data-content--editor--table-target=content] th,
1477
+ [data-content--editor--table-target=content] td {
1478
+ border: 1px solid #ececec;
1479
+ padding: 0.25rem 0.5rem;
1480
+ text-align: left;
1481
+ vertical-align: top;
1482
+ }
1483
+ [data-content--editor--table-target=content] thead {
1484
+ background-color: #ececec;
1485
+ }
1486
+ [data-content--editor--table-target=content] tbody th {
1487
+ background-color: #f4f4f4;
1488
+ }
1489
+
1374
1490
  trix-editor {
1375
1491
  border: 1px solid #bbb;
1376
1492
  border-radius: 3px;
@@ -2075,6 +2191,30 @@ trix-editor .attachment__metadata .attachment__size {
2075
2191
  --heading--h4: 1rem;
2076
2192
  }
2077
2193
 
2194
+ [data-controller=content--editor--table] .content--editor--table-editor:not(:has(table)) {
2195
+ min-height: 4rem !important;
2196
+ }
2197
+ [data-controller=content--editor--table] .content--editor--table-editor:has(table) {
2198
+ border: none !important;
2199
+ padding: 0 !important;
2200
+ }
2201
+ [data-controller=content--editor--table] .content--editor--table-editor table {
2202
+ width: 100%;
2203
+ }
2204
+ [data-controller=content--editor--table] .content--editor--table-editor table,
2205
+ [data-controller=content--editor--table] .content--editor--table-editor th,
2206
+ [data-controller=content--editor--table] .content--editor--table-editor td {
2207
+ border: 2px solid black;
2208
+ }
2209
+ [data-controller=content--editor--table] input[type=number]::-webkit-inner-spin-button {
2210
+ position: relative;
2211
+ right: -1px;
2212
+ margin-top: -2px;
2213
+ margin-bottom: -4px;
2214
+ -webkit-appearance: inner-spin-button !important;
2215
+ opacity: 1 !important;
2216
+ }
2217
+
2078
2218
 
2079
2219
 
2080
2220
 
@@ -2119,7 +2259,10 @@ trix-editor .attachment__metadata .attachment__size {
2119
2259
 
2120
2260
 
2121
2261
  :root {
2122
- --govuk-frontend-version: "5.0.0";
2262
+ --govuk-frontend-version: "5.2.0";
2263
+ --govuk-frontend-breakpoint-mobile: 20rem;
2264
+ --govuk-frontend-breakpoint-tablet: 40.0625rem;
2265
+ --govuk-frontend-breakpoint-desktop: 48.0625rem;
2123
2266
  }
2124
2267
 
2125
2268
 
@@ -3896,12 +4039,10 @@ trix-editor .attachment__metadata .attachment__size {
3896
4039
 
3897
4040
 
3898
4041
  .govuk-checkboxes__item {
3899
- display: block;
4042
+ display: flex;
4043
+ flex-wrap: wrap;
3900
4044
  position: relative;
3901
- min-height: 40px;
3902
4045
  margin-bottom: 10px;
3903
- padding-left: 40px;
3904
- clear: left;
3905
4046
  }
3906
4047
 
3907
4048
  .govuk-checkboxes__item:last-child,
@@ -3910,10 +4051,7 @@ trix-editor .attachment__metadata .attachment__size {
3910
4051
  }
3911
4052
 
3912
4053
  .govuk-checkboxes__input {
3913
- position: absolute;
3914
4054
  z-index: 1;
3915
- top: -2px;
3916
- left: -2px;
3917
4055
  width: 44px;
3918
4056
  height: 44px;
3919
4057
  margin: 0;
@@ -3922,9 +4060,10 @@ trix-editor .attachment__metadata .attachment__size {
3922
4060
  }
3923
4061
 
3924
4062
  .govuk-checkboxes__label {
3925
- display: inline-block;
4063
+ align-self: center;
4064
+ max-width: calc(100% - 74px);
3926
4065
  margin-bottom: 0;
3927
- padding: 8px 15px 5px;
4066
+ padding: 7px 15px;
3928
4067
  cursor: pointer;
3929
4068
  touch-action: manipulation;
3930
4069
  }
@@ -3933,8 +4072,8 @@ trix-editor .attachment__metadata .attachment__size {
3933
4072
  content: "";
3934
4073
  box-sizing: border-box;
3935
4074
  position: absolute;
3936
- top: 0;
3937
- left: 0;
4075
+ top: 2px;
4076
+ left: 2px;
3938
4077
  width: 40px;
3939
4078
  height: 40px;
3940
4079
  border: 2px solid currentcolor;
@@ -3945,8 +4084,8 @@ trix-editor .attachment__metadata .attachment__size {
3945
4084
  content: "";
3946
4085
  box-sizing: border-box;
3947
4086
  position: absolute;
3948
- top: 11px;
3949
- left: 9px;
4087
+ top: 13px;
4088
+ left: 10px;
3950
4089
  width: 23px;
3951
4090
  height: 12px;
3952
4091
  transform: rotate(-45deg);
@@ -3959,8 +4098,14 @@ trix-editor .attachment__metadata .attachment__size {
3959
4098
 
3960
4099
  .govuk-checkboxes__hint {
3961
4100
  display: block;
4101
+ width: 100%;
4102
+ margin-top: -5px;
3962
4103
  padding-right: 15px;
3963
- padding-left: 15px;
4104
+ padding-left: 59px;
4105
+ }
4106
+
4107
+ .govuk-label:not(.govuk-label--m):not(.govuk-label--l):not(.govuk-label--xl) + .govuk-checkboxes__hint {
4108
+ margin-bottom: 0;
3964
4109
  }
3965
4110
 
3966
4111
  .govuk-checkboxes__input:focus + .govuk-checkboxes__label::before {
@@ -4043,49 +4188,33 @@ trix-editor .attachment__metadata .attachment__size {
4043
4188
  }
4044
4189
 
4045
4190
  .govuk-checkboxes--small .govuk-checkboxes__item {
4046
- min-height: 0;
4047
4191
  margin-bottom: 0;
4048
- padding-left: 34px;
4049
- float: left;
4050
- }
4051
- .govuk-checkboxes--small .govuk-checkboxes__item::after {
4052
- content: "";
4053
- display: block;
4054
- clear: both;
4055
4192
  }
4056
4193
  .govuk-checkboxes--small .govuk-checkboxes__input {
4057
- left: -10px;
4194
+ margin-left: -10px;
4058
4195
  }
4059
4196
  .govuk-checkboxes--small .govuk-checkboxes__label {
4060
- margin-top: -2px;
4061
- padding: 13px 15px 13px 1px;
4062
- float: left;
4063
- }
4064
- @media (min-width: 40.0625em) {
4065
- .govuk-checkboxes--small .govuk-checkboxes__label {
4066
- padding: 11px 15px 10px 1px;
4067
- }
4197
+ padding-left: 1px;
4068
4198
  }
4069
4199
  .govuk-checkboxes--small .govuk-checkboxes__label::before {
4070
- top: 8px;
4200
+ top: 10px;
4201
+ left: 0;
4071
4202
  width: 24px;
4072
4203
  height: 24px;
4073
4204
  }
4074
4205
  .govuk-checkboxes--small .govuk-checkboxes__label::after {
4075
- top: 15px;
4206
+ top: 17px;
4076
4207
  left: 6px;
4077
4208
  width: 12px;
4078
4209
  height: 6.5px;
4079
4210
  border-width: 0 0 3px 3px;
4080
4211
  }
4081
4212
  .govuk-checkboxes--small .govuk-checkboxes__hint {
4082
- padding: 0;
4083
- clear: both;
4213
+ padding-left: 34px;
4084
4214
  }
4085
4215
  .govuk-checkboxes--small .govuk-checkboxes__conditional {
4086
4216
  margin-left: 10px;
4087
4217
  padding-left: 20px;
4088
- clear: both;
4089
4218
  }
4090
4219
  .govuk-checkboxes--small .govuk-checkboxes__item:hover .govuk-checkboxes__input:not(:disabled) + .govuk-checkboxes__label::before {
4091
4220
  outline: 3px dashed transparent;
@@ -4178,24 +4307,9 @@ trix-editor .attachment__metadata .attachment__size {
4178
4307
  }
4179
4308
 
4180
4309
  .govuk-input--extra-letter-spacing {
4181
- font-family: "Inter";
4182
- -webkit-font-smoothing: antialiased;
4183
- -moz-osx-font-smoothing: grayscale;
4184
- font-feature-settings: "tnum" 1;
4185
- font-weight: 400;
4310
+ font-variant-numeric: tabular-nums;
4186
4311
  letter-spacing: 0.05em;
4187
4312
  }
4188
- @media print {
4189
- .govuk-input--extra-letter-spacing {
4190
- font-family: sans-serif;
4191
- }
4192
- }
4193
- @supports (font-variant-numeric: tabular-nums) {
4194
- .govuk-input--extra-letter-spacing {
4195
- font-feature-settings: normal;
4196
- font-variant-numeric: tabular-nums;
4197
- }
4198
- }
4199
4313
 
4200
4314
  .govuk-input--width-30 {
4201
4315
  max-width: 29.5em;
@@ -4252,7 +4366,9 @@ trix-editor .attachment__metadata .attachment__size {
4252
4366
  font-size: 1rem;
4253
4367
  line-height: 1.5;
4254
4368
  box-sizing: border-box;
4255
- display: inline-block;
4369
+ display: flex;
4370
+ align-items: center;
4371
+ justify-content: center;
4256
4372
  min-width: 2.5rem;
4257
4373
  height: 2.5rem;
4258
4374
  padding: 5px;
@@ -4283,12 +4399,6 @@ trix-editor .attachment__metadata .attachment__size {
4283
4399
  line-height: 1.5;
4284
4400
  }
4285
4401
  }
4286
- @media (max-width: 40.0525em) {
4287
- .govuk-input__prefix,
4288
- .govuk-input__suffix {
4289
- line-height: 1.6;
4290
- }
4291
- }
4292
4402
  @media (max-width: 19.99em) {
4293
4403
  .govuk-input__prefix,
4294
4404
  .govuk-input__suffix {
@@ -4549,12 +4659,10 @@ trix-editor .attachment__metadata .attachment__size {
4549
4659
 
4550
4660
 
4551
4661
  .govuk-radios__item {
4552
- display: block;
4662
+ display: flex;
4663
+ flex-wrap: wrap;
4553
4664
  position: relative;
4554
- min-height: 40px;
4555
4665
  margin-bottom: 10px;
4556
- padding-left: 40px;
4557
- clear: left;
4558
4666
  }
4559
4667
 
4560
4668
  .govuk-radios__item:last-child,
@@ -4563,10 +4671,7 @@ trix-editor .attachment__metadata .attachment__size {
4563
4671
  }
4564
4672
 
4565
4673
  .govuk-radios__input {
4566
- position: absolute;
4567
4674
  z-index: 1;
4568
- top: -2px;
4569
- left: -2px;
4570
4675
  width: 44px;
4571
4676
  height: 44px;
4572
4677
  margin: 0;
@@ -4575,9 +4680,10 @@ trix-editor .attachment__metadata .attachment__size {
4575
4680
  }
4576
4681
 
4577
4682
  .govuk-radios__label {
4578
- display: inline-block;
4683
+ align-self: center;
4684
+ max-width: calc(100% - 74px);
4579
4685
  margin-bottom: 0;
4580
- padding: 8px 15px 5px;
4686
+ padding: 7px 15px;
4581
4687
  cursor: pointer;
4582
4688
  touch-action: manipulation;
4583
4689
  }
@@ -4586,8 +4692,8 @@ trix-editor .attachment__metadata .attachment__size {
4586
4692
  content: "";
4587
4693
  box-sizing: border-box;
4588
4694
  position: absolute;
4589
- top: 0;
4590
- left: 0;
4695
+ top: 2px;
4696
+ left: 2px;
4591
4697
  width: 40px;
4592
4698
  height: 40px;
4593
4699
  border: 2px solid currentcolor;
@@ -4598,8 +4704,8 @@ trix-editor .attachment__metadata .attachment__size {
4598
4704
  .govuk-radios__label::after {
4599
4705
  content: "";
4600
4706
  position: absolute;
4601
- top: 10px;
4602
- left: 10px;
4707
+ top: 12px;
4708
+ left: 12px;
4603
4709
  width: 0;
4604
4710
  height: 0;
4605
4711
  border: 10px solid currentcolor;
@@ -4610,8 +4716,14 @@ trix-editor .attachment__metadata .attachment__size {
4610
4716
 
4611
4717
  .govuk-radios__hint {
4612
4718
  display: block;
4719
+ width: 100%;
4720
+ margin-top: -5px;
4613
4721
  padding-right: 15px;
4614
- padding-left: 15px;
4722
+ padding-left: 59px;
4723
+ }
4724
+
4725
+ .govuk-label:not(.govuk-label--m):not(.govuk-label--l):not(.govuk-label--xl) + .govuk-radios__hint {
4726
+ margin-bottom: 0;
4615
4727
  }
4616
4728
 
4617
4729
  .govuk-radios__input:focus + .govuk-radios__label::before {
@@ -4641,15 +4753,13 @@ trix-editor .attachment__metadata .attachment__size {
4641
4753
  }
4642
4754
 
4643
4755
  @media (min-width: 40.0625em) {
4644
- .govuk-radios--inline::after {
4645
- content: "";
4646
- display: block;
4647
- clear: both;
4756
+ .govuk-radios--inline {
4757
+ display: flex;
4758
+ flex-wrap: wrap;
4759
+ align-items: flex-start;
4648
4760
  }
4649
4761
  .govuk-radios--inline .govuk-radios__item {
4650
4762
  margin-right: 20px;
4651
- float: left;
4652
- clear: none;
4653
4763
  }
4654
4764
  }
4655
4765
 
@@ -4707,48 +4817,31 @@ trix-editor .attachment__metadata .attachment__size {
4707
4817
  }
4708
4818
 
4709
4819
  .govuk-radios--small .govuk-radios__item {
4710
- min-height: 0;
4711
4820
  margin-bottom: 0;
4712
- padding-left: 34px;
4713
- float: left;
4714
- }
4715
- .govuk-radios--small .govuk-radios__item::after {
4716
- content: "";
4717
- display: block;
4718
- clear: both;
4719
4821
  }
4720
4822
  .govuk-radios--small .govuk-radios__input {
4721
- left: -10px;
4823
+ margin-left: -10px;
4722
4824
  }
4723
4825
  .govuk-radios--small .govuk-radios__label {
4724
- margin-top: -2px;
4725
- padding: 13px 15px 13px 1px;
4726
- float: left;
4727
- }
4728
- @media (min-width: 40.0625em) {
4729
- .govuk-radios--small .govuk-radios__label {
4730
- padding: 11px 15px 10px 1px;
4731
- }
4826
+ padding-left: 1px;
4732
4827
  }
4733
4828
  .govuk-radios--small .govuk-radios__label::before {
4734
- top: 8px;
4829
+ top: 10px;
4830
+ left: 0;
4735
4831
  width: 24px;
4736
4832
  height: 24px;
4737
4833
  }
4738
4834
  .govuk-radios--small .govuk-radios__label::after {
4739
- top: 15px;
4835
+ top: 17px;
4740
4836
  left: 7px;
4741
4837
  border-width: 5px;
4742
4838
  }
4743
4839
  .govuk-radios--small .govuk-radios__hint {
4744
- padding: 0;
4745
- clear: both;
4746
- pointer-events: none;
4840
+ padding-left: 34px;
4747
4841
  }
4748
4842
  .govuk-radios--small .govuk-radios__conditional {
4749
4843
  margin-left: 10px;
4750
4844
  padding-left: 20px;
4751
- clear: both;
4752
4845
  }
4753
4846
  .govuk-radios--small .govuk-radios__divider {
4754
4847
  width: 24px;