@navikt/aksel-stylelint 6.2.0 → 6.3.1

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.
Files changed (2) hide show
  1. package/dist/index.css +206 -3
  2. package/package.json +3 -3
package/dist/index.css CHANGED
@@ -1,7 +1,7 @@
1
1
  @charset "UTF-8";
2
2
  /**
3
3
  * Do not edit directly
4
- * Generated on Thu, 14 Mar 2024 15:17:13 GMT
4
+ * Generated on Tue, 19 Mar 2024 14:09:09 GMT
5
5
  */
6
6
  :root, :host {
7
7
  --a-spacing-1-alt: 0.375rem;
@@ -2625,6 +2625,207 @@ body,
2625
2625
  opacity: 1;
2626
2626
  }
2627
2627
  }
2628
+ /**
2629
+ * Makes it easier for user to use FileItem in semantic lists
2630
+ */
2631
+ .navds-file-upload :is(ul, li) {
2632
+ list-style: none;
2633
+ margin: 0;
2634
+ padding: 0;
2635
+ }
2636
+ /**
2637
+ * FileUpload.Dropzone
2638
+ */
2639
+ .navds-dropzone__area {
2640
+ --__ac-dropzone-background: var(--a-surface-subtle);
2641
+ --__ac-dropzone-text-color: var(--a-text-default);
2642
+ --__ac-dropzone-padding: var(--a-spacing-6);
2643
+ --__ac-dropzone-icon-padding: var(--a-spacing-2);
2644
+ --__ac-dropzone-animation-length-long: 0.6s;
2645
+ --__ac-dropzone-animation-length-short: 250ms;
2646
+ --__ac-dropzone-animation-ease-out: cubic-bezier(0.3, 1, 0.3, 1);
2647
+ --__ac-dropzone-animation-over-under: cubic-bezier(0.3, 1.4, 0.3, 1);
2648
+
2649
+ position: relative;
2650
+ width: 100%;
2651
+ display: flex;
2652
+ align-items: center;
2653
+ flex-direction: column;
2654
+ gap: var(--a-spacing-4);
2655
+ text-align: center;
2656
+ padding: var(--__ac-dropzone-padding);
2657
+ outline: 1px dashed var(--a-border-subtle);
2658
+ outline-offset: -1px;
2659
+ border-radius: var(--a-border-radius-large);
2660
+ background-color: var(--__ac-dropzone-background);
2661
+ color: var(--__ac-dropzone-text-color);
2662
+ transition: background-color var(--__ac-dropzone-animation-length-short) var(--__ac-dropzone-animation-ease-out);
2663
+ cursor: pointer;
2664
+ }
2665
+ .navds-dropzone__area:hover {
2666
+ box-shadow: inset 0 2px 4px 1px rgb(11 11 11/ 0.05);
2667
+ outline-color: var(--a-border-default);
2668
+ }
2669
+ .navds-dropzone--disabled > .navds-dropzone__area:hover {
2670
+ outline-color: var(--a-border-subtle);
2671
+ box-shadow: initial;
2672
+ cursor: default;
2673
+ }
2674
+ .navds-dropzone--dragging > .navds-dropzone__area {
2675
+ --__ac-dropzone-background: var(--a-surface-action-subtle-hover);
2676
+ }
2677
+ .navds-dropzone--dragging > .navds-dropzone__area::after {
2678
+ outline: 1px dashed var(--a-border-subtle);
2679
+ outline-offset: -1px;
2680
+ color: var(--a-text-action-selected);
2681
+ background-color: var(--a-surface-hover);
2682
+ content: "";
2683
+ inset: 0;
2684
+ position: absolute;
2685
+ -webkit-backdrop-filter: blur(8px);
2686
+ backdrop-filter: blur(8px);
2687
+ box-shadow: inset 0 2px 7px 3px rgb(11 11 11/ 0.1);
2688
+ border-radius: var(--a-border-radius-large);
2689
+ animation: akselDropzoneDragoverAnimation var(--__ac-dropzone-animation-length-short) var(--__ac-dropzone-animation-ease-out);
2690
+ }
2691
+ @keyframes akselDropzoneDragoverAnimation {
2692
+ 0% {
2693
+ -webkit-backdrop-filter: blur(0);
2694
+ backdrop-filter: blur(0);
2695
+ background-color: var(--a-surface-transparent);
2696
+ }
2697
+
2698
+ 70% {
2699
+ -webkit-backdrop-filter: blur(8px);
2700
+ backdrop-filter: blur(8px);
2701
+ }
2702
+
2703
+ 100% {
2704
+ background-color: var(--a-surface-hover);
2705
+ }
2706
+ }
2707
+ .navds-dropzone__area-icon {
2708
+ display: grid;
2709
+ padding: var(--__ac-dropzone-icon-padding);
2710
+ visibility: hidden;
2711
+ }
2712
+ .navds-dropzone--error:where(:not(.navds-dropzone--dragging)) > .navds-dropzone__area {
2713
+ outline-color: var(--a-surface-danger);
2714
+ outline-width: 2px;
2715
+ }
2716
+ .navds-dropzone__area:hover > .navds-dropzone__area-button {
2717
+ color: var(--ac-button-secondary-hover-text, var(--__ac-button-secondary-hover-text, var(--a-text-action-on-action-subtle)));
2718
+ background-color: var(
2719
+ --ac-button-secondary-hover-bg,
2720
+ var(--__ac-button-secondary-hover-bg, var(--a-surface-action-subtle-hover))
2721
+ );
2722
+ }
2723
+ .navds-dropzone__area:active .navds-dropzone__area-button {
2724
+ color: var(--ac-button-secondary-active-text, var(--__ac-button-secondary-active-text, var(--a-text-on-action)));
2725
+ background-color: var(--ac-button-secondary-active-bg, var(--__ac-button-secondary-active-bg, var(--a-surface-action-active)));
2726
+ box-shadow: none;
2727
+ }
2728
+ .navds-dropzone__area-release {
2729
+ top: var(--__ac-dropzone-padding);
2730
+ display: grid;
2731
+ position: absolute;
2732
+ z-index: 1;
2733
+ pointer-events: none;
2734
+ transition:
2735
+ top var(--__ac-dropzone-animation-length-long) var(--__ac-dropzone-animation-over-under),
2736
+ transform var(--__ac-dropzone-animation-length-long) var(--__ac-dropzone-animation-over-under);
2737
+ }
2738
+ .navds-dropzone__area-release__icon {
2739
+ display: grid;
2740
+ padding: var(--__ac-dropzone-icon-padding);
2741
+ border-radius: var(--a-border-radius-full);
2742
+ background-color: var(--a-surface-neutral-subtle);
2743
+ transition:
2744
+ background-color 300ms var(--__ac-dropzone-animation-ease-out),
2745
+ font-size 300ms var(--__ac-dropzone-animation-ease-out);
2746
+ font-size: 1.5rem;
2747
+ }
2748
+ .navds-dropzone--dragging .navds-dropzone__area-release > .navds-dropzone__area-release__icon {
2749
+ background-color: transparent;
2750
+ font-size: 2rem;
2751
+ }
2752
+ .navds-dropzone__area-release__text {
2753
+ visibility: hidden;
2754
+ }
2755
+ .navds-dropzone--dragging .navds-dropzone__area-release > .navds-dropzone__area-release__text {
2756
+ transition: visibility var(--__ac-dropzone-animation-length-long) var(--__ac-dropzone-animation-over-under);
2757
+ visibility: visible;
2758
+ }
2759
+ .navds-dropzone--dragging .navds-dropzone__area-release {
2760
+ color: var(--a-text-action-selected);
2761
+ top: 50%;
2762
+ transform: translateY(-50%);
2763
+ }
2764
+ .navds-dropzone__area-disabled {
2765
+ color: var(--a-text-subtle);
2766
+ display: flex;
2767
+ align-items: center;
2768
+ flex-direction: column;
2769
+ gap: var(--a-spacing-2);
2770
+ }
2771
+ /**
2772
+ * FileUpload.Item
2773
+ */
2774
+ .navds-file-item__inner {
2775
+ outline: 1px solid var(--a-border-subtle);
2776
+ outline-offset: -1px;
2777
+ transition: outline-color 250ms cubic-bezier(0, 0.3, 0.15, 1);
2778
+ border-radius: var(--a-border-radius-large);
2779
+ padding: var(--a-spacing-3);
2780
+ display: flex;
2781
+ gap: var(--a-spacing-3);
2782
+ align-items: flex-start;
2783
+ }
2784
+ .navds-file-item--error > .navds-file-item__inner {
2785
+ outline: 2px solid var(--a-surface-danger);
2786
+ }
2787
+ .navds-file-item__icon {
2788
+ background-color: var(--a-surface-neutral-subtle);
2789
+ color: var(--a-icon-default);
2790
+ border-radius: var(--a-border-radius-xlarge);
2791
+ min-height: 3rem;
2792
+ min-width: 3rem;
2793
+ display: grid;
2794
+ place-content: center;
2795
+ transition: background-color 250ms cubic-bezier(0, 0.3, 0.15, 1);
2796
+ }
2797
+ .navds-file-item__icon--loading {
2798
+ background-color: transparent;
2799
+ }
2800
+ .navds-file-item__file-info {
2801
+ word-break: break-word;
2802
+ }
2803
+ .navds-file-item__button {
2804
+ margin-left: auto;
2805
+ }
2806
+ .navds-file-item__error {
2807
+ color: var(--a-text-danger);
2808
+ display: grid;
2809
+ transition-property: grid-template-rows, padding-top;
2810
+ transition-duration: 250ms;
2811
+ transition-timing-function: cubic-bezier(0, 0.3, 0.15, 1);
2812
+ overflow: hidden;
2813
+ grid-template-rows: 0fr;
2814
+ }
2815
+ .navds-file-item--error .navds-file-item__error {
2816
+ grid-template-rows: 1fr;
2817
+ padding-top: var(--a-spacing-1);
2818
+ }
2819
+ .navds-file-item__error-content > svg {
2820
+ flex-shrink: 0;
2821
+ height: 1rem;
2822
+ margin-top: 0.1rem;
2823
+ }
2824
+ .navds-file-item__error-content {
2825
+ min-height: 0;
2826
+ display: flex;
2827
+ gap: var(--a-spacing-1);
2828
+ }
2628
2829
  .navds-form-field {
2629
2830
  display: grid;
2630
2831
  justify-items: start;
@@ -2635,12 +2836,14 @@ body,
2635
2836
  color: var(--ac-form-description, var(--__ac-form-description, var(--a-text-subtle)));
2636
2837
  }
2637
2838
  .navds-form-field .navds-error-message,
2638
- .navds-fieldset .navds-error-message {
2839
+ .navds-fieldset .navds-error-message,
2840
+ .navds-file-item .navds-error-message {
2639
2841
  display: flex;
2640
2842
  gap: var(--a-spacing-2);
2641
2843
  }
2642
2844
  .navds-form-field .navds-error-message::before,
2643
- .navds-fieldset .navds-error-message::before {
2845
+ .navds-fieldset .navds-error-message::before,
2846
+ .navds-file-item .navds-error-message::before {
2644
2847
  content: "•";
2645
2848
  }
2646
2849
  .navds-form-field--disabled {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@navikt/aksel-stylelint",
3
- "version": "6.2.0",
3
+ "version": "6.3.1",
4
4
  "author": "Aksel | NAV",
5
5
  "homepage": "https://aksel.nav.no/grunnleggende/kode/stylelint",
6
6
  "repository": {
@@ -35,8 +35,8 @@
35
35
  "dev": "yarn watch:lint"
36
36
  },
37
37
  "devDependencies": {
38
- "@navikt/ds-css": "^6.2.0",
39
- "@navikt/ds-tokens": "^6.2.0",
38
+ "@navikt/ds-css": "^6.3.1",
39
+ "@navikt/ds-tokens": "^6.3.1",
40
40
  "concurrently": "7.2.1",
41
41
  "postcss-selector-parser": "^6.0.13",
42
42
  "postcss-value-parser": "^4.2.0",