| 1 |
@use '../sass-utilities' as *; |
| 2 |
@use '../assets/fontawesome/variables' as *; |
| 3 |
|
| 4 |
.#{$pf-prefix}screen-reader { |
| 5 |
@include pf-v6-u-screen-reader; // for use with assistive technologies |
| 6 |
|
| 7 |
&.pf-m-full-size { |
| 8 |
width: 100%; |
| 9 |
height: 100%; |
| 10 |
} |
| 11 |
|
| 12 |
&.pf-m-absolute { |
| 13 |
position: absolute; |
| 14 |
} |
| 15 |
} |
| 16 |
|
| 17 |
.#{$pf-prefix}m-tabular-nums { |
| 18 |
font-variant-numeric: tabular-nums; |
| 19 |
} |
| 20 |
|
| 21 |
// Variable font opt-in |
| 22 |
.#{$pf-prefix}m-legacy-font { |
| 23 |
--pf-t--global--font--family--body: var(--pf-t--global--font--family--body--legacy); |
| 24 |
--pf-t--global--font--family--heading: var(--pf-t--global--font--family--heading--legacy); |
| 25 |
--pf-t--global--font--family--mono: var(--pf-t--global--font--family--mono--legacy); |
| 26 |
--pf-t--global--font--weight--body: var(--pf-t--global--font--weight--body--legacy); |
| 27 |
--pf-t--global--font--weight--body--bold: var(--pf-t--global--font--weight--body--bold--legacy); |
| 28 |
--pf-t--global--font--weight--heading: var(--pf-t--global--font--weight--heading--legacy); |
| 29 |
--pf-t--global--font--weight--heading--bold: var(--pf-t--global--font--weight--heading--bold--legacy); |
| 30 |
} |
| 31 |
|
| 32 |
// RTL helpers |
| 33 |
|
| 34 |
// Sets a block to RTL |
| 35 |
.#{$pf-prefix}m-dir-rtl { |
| 36 |
@include pf-v6-set-inverse; |
| 37 |
|
| 38 |
direction: rtl; |
| 39 |
} |
| 40 |
|
| 41 |
// Sets a block to LTR |
| 42 |
.#{$pf-prefix}m-dir-ltr { |
| 43 |
@include pf-v6-set-inverse(false); |
| 44 |
|
| 45 |
direction: ltr; |
| 46 |
} |
| 47 |
|
| 48 |
// Mirrors/flips something horizontally/inline in RTL |
| 49 |
.#{$pf-prefix}m-mirror-inline-rtl { |
| 50 |
@include pf-v6-mirror-inline-on-rtl; |
| 51 |
} |
| 52 |
|
| 53 |
// Turn off perceptible motion (for testing purposes) by setting all motion tokens to 1ms |
| 54 |
.#{$pf-prefix}m-no-motion { |
| 55 |
// stylelint-disable declaration-no-important |
| 56 |
--pf-t--global--delay--400: 1ms !important; |
| 57 |
--pf-t--global--delay--300: 1ms !important; |
| 58 |
--pf-t--global--delay--200: 1ms !important; |
| 59 |
--pf-t--global--delay--100: 1ms !important; |
| 60 |
--pf-t--global--duration--600: 1ms !important; |
| 61 |
--pf-t--global--duration--500: 1ms !important; |
| 62 |
--pf-t--global--duration--400: 1ms !important; |
| 63 |
--pf-t--global--duration--300: 1ms !important; |
| 64 |
--pf-t--global--duration--200: 1ms !important; |
| 65 |
--pf-t--global--duration--100: 1ms !important; |
| 66 |
--pf-t--global--duration--50: 1ms !important; |
| 67 |
--#{$pf-global}--thinking-active--Animation--Duration: 0 !important; |
| 68 |
|
| 69 |
// stylelink-enable declaration-no-important |
| 70 |
} |
| 71 |
|
| 72 |
.#{$pf-prefix}m-ai-indicator { |
| 73 |
position: relative; |
| 74 |
|
| 75 |
&::before { |
| 76 |
position: absolute; |
| 77 |
inset: 0; |
| 78 |
pointer-events: none; |
| 79 |
content: ""; |
| 80 |
background: linear-gradient(to right, #f56e6e 0%, #876fd4 65%, #5e40be 100%) |
| 81 |
border-box; |
| 82 |
border: var(--pf-t--global--border--width--extra-strong) solid transparent; |
| 83 |
border-radius: inherit; |
| 84 |
mask: linear-gradient(#000 0 0) padding-box, linear-gradient(#000 0 0); |
| 85 |
mask-composite: exclude; |
| 86 |
} |
| 87 |
} |
| 88 |
|
| 89 |
@property --#{$pf-global}--thinking--BoxShadow--Spread { |
| 90 |
syntax: "<length>"; |
| 91 |
initial-value: 0; |
| 92 |
inherits: false; |
| 93 |
} |
| 94 |
|
| 95 |
.#{$pf-prefix}m-thinking { |
| 96 |
box-shadow: 0 0 var(--#{$pf-global}--thinking--BoxShadow--Spread) var(--#{$pf-global}--thinking--BoxShadow--Color--End-End), |
| 97 |
0 0 var(--#{$pf-global}--thinking--BoxShadow--Spread) var(--#{$pf-global}--thinking--BoxShadow--Color--Start-End), |
| 98 |
0 0 var(--#{$pf-global}--thinking--BoxShadow--Spread) var(--#{$pf-global}--thinking--BoxShadow--Color--End-Start), |
| 99 |
0 0 var(--#{$pf-global}--thinking--BoxShadow--Spread) var(--#{$pf-global}--thinking--BoxShadow--Color--Start-Start); |
| 100 |
animation: #{$pf-global}-thinking var(--#{$pf-global}--thinking-active--Animation--Duration) infinite ease-in-out; |
| 101 |
|
| 102 |
&.pf-m-inset { |
| 103 |
box-shadow: inset 0 0 var(--#{$pf-global}--thinking--BoxShadow--Spread) var(--#{$pf-global}--thinking--BoxShadow--Color--End-End), |
| 104 |
inset 0 0 var(--#{$pf-global}--thinking--BoxShadow--Spread) var(--#{$pf-global}--thinking--BoxShadow--Color--Start-End), |
| 105 |
inset 0 0 var(--#{$pf-global}--thinking--BoxShadow--Spread) var(--#{$pf-global}--thinking--BoxShadow--Color--End-Start), |
| 106 |
inset 0 0 var(--#{$pf-global}--thinking--BoxShadow--Spread) var(--#{$pf-global}--thinking--BoxShadow--Color--Start-Start); |
| 107 |
} |
| 108 |
} |
| 109 |
|
| 110 |
@keyframes #{$pf-global}-thinking { |
| 111 |
50% { |
| 112 |
--#{$pf-global}--thinking--BoxShadow--Spread: var(--#{$pf-global}--thinking-active--BoxShadow--Spread); |
| 113 |
} |
| 114 |
} |
| 115 |
|
| 116 |
:root { |
| 117 |
--#{$pf-global}--danger-jiggle--AnimationDuration--Transform: var(--pf-t--global--motion--duration--fade--default); |
| 118 |
--#{$pf-global}--danger-jiggle--AnimationTimingFunction--Transform: var(--pf-t--global--motion--timing-function--default); |
| 119 |
--#{$pf-global}--thinking--BoxShadow--Spread: 0px; |
| 120 |
--#{$pf-global}--thinking--BoxShadow--Color--Start-Start: oklch(45.9% 0.187 3.815deg); |
| 121 |
--#{$pf-global}--thinking--BoxShadow--Color--Start-End: oklch(50% 0.134 242.749deg); |
| 122 |
--#{$pf-global}--thinking--BoxShadow--Color--End-Start: oklch(45.9% 0.187 3.815deg); |
| 123 |
--#{$pf-global}--thinking--BoxShadow--Color--End-End: oklch(43.2% 0.232 292.759deg); |
| 124 |
--#{$pf-global}--thinking-active--BoxShadow--Spread: 15px; |
| 125 |
--#{$pf-global}--thinking-active--Animation--Duration: 0; |
| 126 |
|
| 127 |
@media screen and (prefers-reduced-motion: no-preference) { |
| 128 |
--#{$pf-global}--thinking-active--Animation--Duration: 2s; |
| 129 |
} |
| 130 |
|
| 131 |
container-name: #{$pf-prefix}contain-viewport #{$pf-prefix}contain-table; |
| 132 |
container-type: inline-size; |
| 133 |
} |
| 134 |
|
| 135 |
// Register the property type for the custom property to be animatable |
| 136 |
@property --#{$pf-global}--danger-jiggle--TranslateX { |
| 137 |
syntax: "<length>"; |
| 138 |
inherits: false; |
| 139 |
initial-value: 0; |
| 140 |
} |
| 141 |
|
| 142 |
// Animate danger jiggle |
| 143 |
@keyframes #{$pf-global}-danger-jiggle-motion { |
| 144 |
33% { |
| 145 |
--#{$pf-global}--danger-jiggle--TranslateX: -2px; |
| 146 |
} |
| 147 |
|
| 148 |
66% { |
| 149 |
--#{$pf-global}--danger-jiggle--TranslateX: 3px; |
| 150 |
} |
| 151 |
} |
| 152 |
|
| 153 |
// Animate fade-in |
| 154 |
@keyframes #{$pf-global}-fade-in { |
| 155 |
from { |
| 156 |
opacity: 0; |
| 157 |
} |
| 158 |
|
| 159 |
to { |
| 160 |
opacity: 1; |
| 161 |
} |
| 162 |
} |
| 163 |
|
| 164 |
// Animate fade-out |
| 165 |
@keyframes #{$pf-global}-fade-out { |
| 166 |
from { |
| 167 |
opacity: 1; |
| 168 |
} |
| 169 |
|
| 170 |
to { |
| 171 |
opacity: 0; |
| 172 |
} |
| 173 |
} |