@fremtind/jokul 0.1.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 (358) hide show
  1. package/LICENSE +21 -0
  2. package/build/build-stats.html +4842 -0
  3. package/build/cjs/components/ScreenReaderOnly.js +2 -0
  4. package/build/cjs/components/ScreenReaderOnly.js.map +1 -0
  5. package/build/cjs/components/SlotComponent.js +2 -0
  6. package/build/cjs/components/SlotComponent.js.map +1 -0
  7. package/build/cjs/components/index.js +2 -0
  8. package/build/cjs/components/index.js.map +1 -0
  9. package/build/cjs/components/navigation/Link.js +2 -0
  10. package/build/cjs/components/navigation/Link.js.map +1 -0
  11. package/build/cjs/components/navigation/NavLink.js +2 -0
  12. package/build/cjs/components/navigation/NavLink.js.map +1 -0
  13. package/build/cjs/components/navigation/index.js +2 -0
  14. package/build/cjs/components/navigation/index.js.map +1 -0
  15. package/build/cjs/core/as-child.js +2 -0
  16. package/build/cjs/core/as-child.js.map +1 -0
  17. package/build/cjs/core/index.js +2 -0
  18. package/build/cjs/core/index.js.map +1 -0
  19. package/build/cjs/core/polymorphism.js +2 -0
  20. package/build/cjs/core/polymorphism.js.map +1 -0
  21. package/build/cjs/core/tokens.js +2 -0
  22. package/build/cjs/core/tokens.js.map +1 -0
  23. package/build/cjs/core/types.js +2 -0
  24. package/build/cjs/core/types.js.map +1 -0
  25. package/build/cjs/core/utils/breakpoints.js +2 -0
  26. package/build/cjs/core/utils/breakpoints.js.map +1 -0
  27. package/build/cjs/core/utils/density.js +2 -0
  28. package/build/cjs/core/utils/density.js.map +1 -0
  29. package/build/cjs/core/utils/getValuePair.js +2 -0
  30. package/build/cjs/core/utils/getValuePair.js.map +1 -0
  31. package/build/cjs/core/utils/index.js +2 -0
  32. package/build/cjs/core/utils/index.js.map +1 -0
  33. package/build/cjs/core/utils/mergeProps.js +2 -0
  34. package/build/cjs/core/utils/mergeProps.js.map +1 -0
  35. package/build/cjs/core/utils/mergeRefs.js +2 -0
  36. package/build/cjs/core/utils/mergeRefs.js.map +1 -0
  37. package/build/cjs/core/utils/motion.js +2 -0
  38. package/build/cjs/core/utils/motion.js.map +1 -0
  39. package/build/cjs/core/utils/tabListener.js +2 -0
  40. package/build/cjs/core/utils/tabListener.js.map +1 -0
  41. package/build/cjs/hooks/index.js +2 -0
  42. package/build/cjs/hooks/index.js.map +1 -0
  43. package/build/cjs/hooks/mediaQueryUtils.js +2 -0
  44. package/build/cjs/hooks/mediaQueryUtils.js.map +1 -0
  45. package/build/cjs/hooks/useAnimatedDetails/index.js +2 -0
  46. package/build/cjs/hooks/useAnimatedDetails/index.js.map +1 -0
  47. package/build/cjs/hooks/useAnimatedDetails/useAnimatedDetails.js +2 -0
  48. package/build/cjs/hooks/useAnimatedDetails/useAnimatedDetails.js.map +1 -0
  49. package/build/cjs/hooks/useAnimatedHeight/index.js +2 -0
  50. package/build/cjs/hooks/useAnimatedHeight/index.js.map +1 -0
  51. package/build/cjs/hooks/useAnimatedHeight/types.js +2 -0
  52. package/build/cjs/hooks/useAnimatedHeight/types.js.map +1 -0
  53. package/build/cjs/hooks/useAnimatedHeight/useAnimatedHeight.js +2 -0
  54. package/build/cjs/hooks/useAnimatedHeight/useAnimatedHeight.js.map +1 -0
  55. package/build/cjs/hooks/useAnimatedHeight/useAnimatedHeightBetween.js +2 -0
  56. package/build/cjs/hooks/useAnimatedHeight/useAnimatedHeightBetween.js.map +1 -0
  57. package/build/cjs/hooks/useAnimatedHeight/useAutoAnimateHeight.js +2 -0
  58. package/build/cjs/hooks/useAnimatedHeight/useAutoAnimateHeight.js.map +1 -0
  59. package/build/cjs/hooks/useAriaLiveRegion/index.js +2 -0
  60. package/build/cjs/hooks/useAriaLiveRegion/index.js.map +1 -0
  61. package/build/cjs/hooks/useAriaLiveRegion/useAriaLiveRegion.js +2 -0
  62. package/build/cjs/hooks/useAriaLiveRegion/useAriaLiveRegion.js.map +1 -0
  63. package/build/cjs/hooks/useBrowserPreferences/index.js +2 -0
  64. package/build/cjs/hooks/useBrowserPreferences/index.js.map +1 -0
  65. package/build/cjs/hooks/useBrowserPreferences/useBrowserPreferences.js +2 -0
  66. package/build/cjs/hooks/useBrowserPreferences/useBrowserPreferences.js.map +1 -0
  67. package/build/cjs/hooks/useClickOutside/index.js +2 -0
  68. package/build/cjs/hooks/useClickOutside/index.js.map +1 -0
  69. package/build/cjs/hooks/useClickOutside/useClickOutside.js +2 -0
  70. package/build/cjs/hooks/useClickOutside/useClickOutside.js.map +1 -0
  71. package/build/cjs/hooks/useElementDimensions/index.js +2 -0
  72. package/build/cjs/hooks/useElementDimensions/index.js.map +1 -0
  73. package/build/cjs/hooks/useElementDimensions/useElementDimensions.js +2 -0
  74. package/build/cjs/hooks/useElementDimensions/useElementDimensions.js.map +1 -0
  75. package/build/cjs/hooks/useFocusOutside/index.js +2 -0
  76. package/build/cjs/hooks/useFocusOutside/index.js.map +1 -0
  77. package/build/cjs/hooks/useFocusOutside/useFocusOutside.js +2 -0
  78. package/build/cjs/hooks/useFocusOutside/useFocusOutside.js.map +1 -0
  79. package/build/cjs/hooks/useId/index.js +2 -0
  80. package/build/cjs/hooks/useId/index.js.map +1 -0
  81. package/build/cjs/hooks/useId/useId.js +2 -0
  82. package/build/cjs/hooks/useId/useId.js.map +1 -0
  83. package/build/cjs/hooks/useIntersectionObserver/index.js +2 -0
  84. package/build/cjs/hooks/useIntersectionObserver/index.js.map +1 -0
  85. package/build/cjs/hooks/useIntersectionObserver/useIntersectionObserver.js +2 -0
  86. package/build/cjs/hooks/useIntersectionObserver/useIntersectionObserver.js.map +1 -0
  87. package/build/cjs/hooks/useKeyListener/index.js +2 -0
  88. package/build/cjs/hooks/useKeyListener/index.js.map +1 -0
  89. package/build/cjs/hooks/useKeyListener/useKeyListener.js +2 -0
  90. package/build/cjs/hooks/useKeyListener/useKeyListener.js.map +1 -0
  91. package/build/cjs/hooks/useListNavigation/index.js +2 -0
  92. package/build/cjs/hooks/useListNavigation/index.js.map +1 -0
  93. package/build/cjs/hooks/useListNavigation/useListNavigation.js +2 -0
  94. package/build/cjs/hooks/useListNavigation/useListNavigation.js.map +1 -0
  95. package/build/cjs/hooks/useLocalStorage/index.js +2 -0
  96. package/build/cjs/hooks/useLocalStorage/index.js.map +1 -0
  97. package/build/cjs/hooks/useLocalStorage/useLocalStorage.js +2 -0
  98. package/build/cjs/hooks/useLocalStorage/useLocalStorage.js.map +1 -0
  99. package/build/cjs/hooks/useMutationObserver/index.js +2 -0
  100. package/build/cjs/hooks/useMutationObserver/index.js.map +1 -0
  101. package/build/cjs/hooks/useMutationObserver/useMutationObserver.js +2 -0
  102. package/build/cjs/hooks/useMutationObserver/useMutationObserver.js.map +1 -0
  103. package/build/cjs/hooks/usePreviousValue/index.js +2 -0
  104. package/build/cjs/hooks/usePreviousValue/index.js.map +1 -0
  105. package/build/cjs/hooks/usePreviousValue/usePreviousValue.js +2 -0
  106. package/build/cjs/hooks/usePreviousValue/usePreviousValue.js.map +1 -0
  107. package/build/cjs/hooks/useProgressiveImg/index.js +2 -0
  108. package/build/cjs/hooks/useProgressiveImg/index.js.map +1 -0
  109. package/build/cjs/hooks/useProgressiveImg/useProgressiveImg.js +2 -0
  110. package/build/cjs/hooks/useProgressiveImg/useProgressiveImg.js.map +1 -0
  111. package/build/cjs/hooks/useScreen/index.js +2 -0
  112. package/build/cjs/hooks/useScreen/index.js.map +1 -0
  113. package/build/cjs/hooks/useScreen/state.js +2 -0
  114. package/build/cjs/hooks/useScreen/state.js.map +1 -0
  115. package/build/cjs/hooks/useScreen/useScreen.js +2 -0
  116. package/build/cjs/hooks/useScreen/useScreen.js.map +1 -0
  117. package/build/cjs/hooks/useScrollIntoView/index.js +2 -0
  118. package/build/cjs/hooks/useScrollIntoView/index.js.map +1 -0
  119. package/build/cjs/hooks/useScrollIntoView/useScrollIntoView.js +2 -0
  120. package/build/cjs/hooks/useScrollIntoView/useScrollIntoView.js.map +1 -0
  121. package/build/cjs/hooks/useSwipeGesture/index.js +2 -0
  122. package/build/cjs/hooks/useSwipeGesture/index.js.map +1 -0
  123. package/build/cjs/hooks/useSwipeGesture/useSwipeGesture.js +2 -0
  124. package/build/cjs/hooks/useSwipeGesture/useSwipeGesture.js.map +1 -0
  125. package/build/clsx-BeLtu-UY.js +2 -0
  126. package/build/clsx-BeLtu-UY.js.map +1 -0
  127. package/build/clsx-E3yX_9sL.cjs +2 -0
  128. package/build/clsx-E3yX_9sL.cjs.map +1 -0
  129. package/build/components/ScreenReaderOnly.d.ts +6 -0
  130. package/build/components/SlotComponent.d.ts +7 -0
  131. package/build/components/index.d.ts +2 -0
  132. package/build/components/navigation/Link.d.ts +5 -0
  133. package/build/components/navigation/NavLink.d.ts +6 -0
  134. package/build/components/navigation/index.d.ts +2 -0
  135. package/build/core/as-child.d.ts +39 -0
  136. package/build/core/index.d.ts +7 -0
  137. package/build/core/polymorphism.d.ts +11 -0
  138. package/build/core/tokens.d.ts +351 -0
  139. package/build/core/types.d.ts +42 -0
  140. package/build/core/utils/breakpoints.d.ts +6 -0
  141. package/build/core/utils/density.d.ts +1 -0
  142. package/build/core/utils/getValuePair.d.ts +2 -0
  143. package/build/core/utils/index.d.ts +8 -0
  144. package/build/core/utils/mergeProps.d.ts +3 -0
  145. package/build/core/utils/mergeRefs.d.ts +3 -0
  146. package/build/core/utils/motion.d.ts +16 -0
  147. package/build/core/utils/tabListener.d.ts +1 -0
  148. package/build/es/components/ScreenReaderOnly.js +2 -0
  149. package/build/es/components/ScreenReaderOnly.js.map +1 -0
  150. package/build/es/components/SlotComponent.js +2 -0
  151. package/build/es/components/SlotComponent.js.map +1 -0
  152. package/build/es/components/index.js +2 -0
  153. package/build/es/components/index.js.map +1 -0
  154. package/build/es/components/navigation/Link.js +2 -0
  155. package/build/es/components/navigation/Link.js.map +1 -0
  156. package/build/es/components/navigation/NavLink.js +2 -0
  157. package/build/es/components/navigation/NavLink.js.map +1 -0
  158. package/build/es/components/navigation/index.js +2 -0
  159. package/build/es/components/navigation/index.js.map +1 -0
  160. package/build/es/core/as-child.js +2 -0
  161. package/build/es/core/as-child.js.map +1 -0
  162. package/build/es/core/index.js +2 -0
  163. package/build/es/core/index.js.map +1 -0
  164. package/build/es/core/polymorphism.js +2 -0
  165. package/build/es/core/polymorphism.js.map +1 -0
  166. package/build/es/core/tokens.js +2 -0
  167. package/build/es/core/tokens.js.map +1 -0
  168. package/build/es/core/types.js +2 -0
  169. package/build/es/core/types.js.map +1 -0
  170. package/build/es/core/utils/breakpoints.js +2 -0
  171. package/build/es/core/utils/breakpoints.js.map +1 -0
  172. package/build/es/core/utils/density.js +2 -0
  173. package/build/es/core/utils/density.js.map +1 -0
  174. package/build/es/core/utils/getValuePair.js +2 -0
  175. package/build/es/core/utils/getValuePair.js.map +1 -0
  176. package/build/es/core/utils/index.js +2 -0
  177. package/build/es/core/utils/index.js.map +1 -0
  178. package/build/es/core/utils/mergeProps.js +2 -0
  179. package/build/es/core/utils/mergeProps.js.map +1 -0
  180. package/build/es/core/utils/mergeRefs.js +2 -0
  181. package/build/es/core/utils/mergeRefs.js.map +1 -0
  182. package/build/es/core/utils/motion.js +2 -0
  183. package/build/es/core/utils/motion.js.map +1 -0
  184. package/build/es/core/utils/tabListener.js +2 -0
  185. package/build/es/core/utils/tabListener.js.map +1 -0
  186. package/build/es/hooks/index.js +2 -0
  187. package/build/es/hooks/index.js.map +1 -0
  188. package/build/es/hooks/mediaQueryUtils.js +2 -0
  189. package/build/es/hooks/mediaQueryUtils.js.map +1 -0
  190. package/build/es/hooks/useAnimatedDetails/index.js +2 -0
  191. package/build/es/hooks/useAnimatedDetails/index.js.map +1 -0
  192. package/build/es/hooks/useAnimatedDetails/useAnimatedDetails.js +2 -0
  193. package/build/es/hooks/useAnimatedDetails/useAnimatedDetails.js.map +1 -0
  194. package/build/es/hooks/useAnimatedHeight/index.js +2 -0
  195. package/build/es/hooks/useAnimatedHeight/index.js.map +1 -0
  196. package/build/es/hooks/useAnimatedHeight/types.js +2 -0
  197. package/build/es/hooks/useAnimatedHeight/types.js.map +1 -0
  198. package/build/es/hooks/useAnimatedHeight/useAnimatedHeight.js +2 -0
  199. package/build/es/hooks/useAnimatedHeight/useAnimatedHeight.js.map +1 -0
  200. package/build/es/hooks/useAnimatedHeight/useAnimatedHeightBetween.js +2 -0
  201. package/build/es/hooks/useAnimatedHeight/useAnimatedHeightBetween.js.map +1 -0
  202. package/build/es/hooks/useAnimatedHeight/useAutoAnimateHeight.js +2 -0
  203. package/build/es/hooks/useAnimatedHeight/useAutoAnimateHeight.js.map +1 -0
  204. package/build/es/hooks/useAriaLiveRegion/index.js +2 -0
  205. package/build/es/hooks/useAriaLiveRegion/index.js.map +1 -0
  206. package/build/es/hooks/useAriaLiveRegion/useAriaLiveRegion.js +2 -0
  207. package/build/es/hooks/useAriaLiveRegion/useAriaLiveRegion.js.map +1 -0
  208. package/build/es/hooks/useBrowserPreferences/index.js +2 -0
  209. package/build/es/hooks/useBrowserPreferences/index.js.map +1 -0
  210. package/build/es/hooks/useBrowserPreferences/useBrowserPreferences.js +2 -0
  211. package/build/es/hooks/useBrowserPreferences/useBrowserPreferences.js.map +1 -0
  212. package/build/es/hooks/useClickOutside/index.js +2 -0
  213. package/build/es/hooks/useClickOutside/index.js.map +1 -0
  214. package/build/es/hooks/useClickOutside/useClickOutside.js +2 -0
  215. package/build/es/hooks/useClickOutside/useClickOutside.js.map +1 -0
  216. package/build/es/hooks/useElementDimensions/index.js +2 -0
  217. package/build/es/hooks/useElementDimensions/index.js.map +1 -0
  218. package/build/es/hooks/useElementDimensions/useElementDimensions.js +2 -0
  219. package/build/es/hooks/useElementDimensions/useElementDimensions.js.map +1 -0
  220. package/build/es/hooks/useFocusOutside/index.js +2 -0
  221. package/build/es/hooks/useFocusOutside/index.js.map +1 -0
  222. package/build/es/hooks/useFocusOutside/useFocusOutside.js +2 -0
  223. package/build/es/hooks/useFocusOutside/useFocusOutside.js.map +1 -0
  224. package/build/es/hooks/useId/index.js +2 -0
  225. package/build/es/hooks/useId/index.js.map +1 -0
  226. package/build/es/hooks/useId/useId.js +2 -0
  227. package/build/es/hooks/useId/useId.js.map +1 -0
  228. package/build/es/hooks/useIntersectionObserver/index.js +2 -0
  229. package/build/es/hooks/useIntersectionObserver/index.js.map +1 -0
  230. package/build/es/hooks/useIntersectionObserver/useIntersectionObserver.js +2 -0
  231. package/build/es/hooks/useIntersectionObserver/useIntersectionObserver.js.map +1 -0
  232. package/build/es/hooks/useKeyListener/index.js +2 -0
  233. package/build/es/hooks/useKeyListener/index.js.map +1 -0
  234. package/build/es/hooks/useKeyListener/useKeyListener.js +2 -0
  235. package/build/es/hooks/useKeyListener/useKeyListener.js.map +1 -0
  236. package/build/es/hooks/useListNavigation/index.js +2 -0
  237. package/build/es/hooks/useListNavigation/index.js.map +1 -0
  238. package/build/es/hooks/useListNavigation/useListNavigation.js +2 -0
  239. package/build/es/hooks/useListNavigation/useListNavigation.js.map +1 -0
  240. package/build/es/hooks/useLocalStorage/index.js +2 -0
  241. package/build/es/hooks/useLocalStorage/index.js.map +1 -0
  242. package/build/es/hooks/useLocalStorage/useLocalStorage.js +2 -0
  243. package/build/es/hooks/useLocalStorage/useLocalStorage.js.map +1 -0
  244. package/build/es/hooks/useMutationObserver/index.js +2 -0
  245. package/build/es/hooks/useMutationObserver/index.js.map +1 -0
  246. package/build/es/hooks/useMutationObserver/useMutationObserver.js +2 -0
  247. package/build/es/hooks/useMutationObserver/useMutationObserver.js.map +1 -0
  248. package/build/es/hooks/usePreviousValue/index.js +2 -0
  249. package/build/es/hooks/usePreviousValue/index.js.map +1 -0
  250. package/build/es/hooks/usePreviousValue/usePreviousValue.js +2 -0
  251. package/build/es/hooks/usePreviousValue/usePreviousValue.js.map +1 -0
  252. package/build/es/hooks/useProgressiveImg/index.js +2 -0
  253. package/build/es/hooks/useProgressiveImg/index.js.map +1 -0
  254. package/build/es/hooks/useProgressiveImg/useProgressiveImg.js +2 -0
  255. package/build/es/hooks/useProgressiveImg/useProgressiveImg.js.map +1 -0
  256. package/build/es/hooks/useScreen/index.js +2 -0
  257. package/build/es/hooks/useScreen/index.js.map +1 -0
  258. package/build/es/hooks/useScreen/state.js +2 -0
  259. package/build/es/hooks/useScreen/state.js.map +1 -0
  260. package/build/es/hooks/useScreen/useScreen.js +2 -0
  261. package/build/es/hooks/useScreen/useScreen.js.map +1 -0
  262. package/build/es/hooks/useScrollIntoView/index.js +2 -0
  263. package/build/es/hooks/useScrollIntoView/index.js.map +1 -0
  264. package/build/es/hooks/useScrollIntoView/useScrollIntoView.js +2 -0
  265. package/build/es/hooks/useScrollIntoView/useScrollIntoView.js.map +1 -0
  266. package/build/es/hooks/useSwipeGesture/index.js +2 -0
  267. package/build/es/hooks/useSwipeGesture/index.js.map +1 -0
  268. package/build/es/hooks/useSwipeGesture/useSwipeGesture.js +2 -0
  269. package/build/es/hooks/useSwipeGesture/useSwipeGesture.js.map +1 -0
  270. package/build/hooks/index.d.ts +18 -0
  271. package/build/hooks/mediaQueryUtils.d.ts +21 -0
  272. package/build/hooks/useAnimatedDetails/index.d.ts +1 -0
  273. package/build/hooks/useAnimatedDetails/useAnimatedDetails.d.ts +20 -0
  274. package/build/hooks/useAnimatedHeight/index.d.ts +4 -0
  275. package/build/hooks/useAnimatedHeight/types.d.ts +26 -0
  276. package/build/hooks/useAnimatedHeight/useAnimatedHeight.d.ts +10 -0
  277. package/build/hooks/useAnimatedHeight/useAnimatedHeightBetween.d.ts +10 -0
  278. package/build/hooks/useAnimatedHeight/useAutoAnimateHeight.d.ts +20 -0
  279. package/build/hooks/useAriaLiveRegion/index.d.ts +1 -0
  280. package/build/hooks/useAriaLiveRegion/useAriaLiveRegion.d.ts +15 -0
  281. package/build/hooks/useBrowserPreferences/index.d.ts +1 -0
  282. package/build/hooks/useBrowserPreferences/useBrowserPreferences.d.ts +12 -0
  283. package/build/hooks/useClickOutside/index.d.ts +1 -0
  284. package/build/hooks/useClickOutside/useClickOutside.d.ts +7 -0
  285. package/build/hooks/useElementDimensions/index.d.ts +1 -0
  286. package/build/hooks/useElementDimensions/useElementDimensions.d.ts +11 -0
  287. package/build/hooks/useFocusOutside/index.d.ts +1 -0
  288. package/build/hooks/useFocusOutside/useFocusOutside.d.ts +7 -0
  289. package/build/hooks/useId/index.d.ts +1 -0
  290. package/build/hooks/useId/useId.d.ts +11 -0
  291. package/build/hooks/useIntersectionObserver/index.d.ts +1 -0
  292. package/build/hooks/useIntersectionObserver/useIntersectionObserver.d.ts +13 -0
  293. package/build/hooks/useKeyListener/index.d.ts +1 -0
  294. package/build/hooks/useKeyListener/useKeyListener.d.ts +8 -0
  295. package/build/hooks/useListNavigation/index.d.ts +1 -0
  296. package/build/hooks/useListNavigation/useListNavigation.d.ts +7 -0
  297. package/build/hooks/useLocalStorage/index.d.ts +1 -0
  298. package/build/hooks/useLocalStorage/useLocalStorage.d.ts +1 -0
  299. package/build/hooks/useMutationObserver/index.d.ts +1 -0
  300. package/build/hooks/useMutationObserver/useMutationObserver.d.ts +9 -0
  301. package/build/hooks/usePreviousValue/index.d.ts +1 -0
  302. package/build/hooks/usePreviousValue/usePreviousValue.d.ts +6 -0
  303. package/build/hooks/useProgressiveImg/index.d.ts +1 -0
  304. package/build/hooks/useProgressiveImg/useProgressiveImg.d.ts +10 -0
  305. package/build/hooks/useScreen/index.d.ts +2 -0
  306. package/build/hooks/useScreen/state.d.ts +17 -0
  307. package/build/hooks/useScreen/useScreen.d.ts +6 -0
  308. package/build/hooks/useScrollIntoView/index.d.ts +1 -0
  309. package/build/hooks/useScrollIntoView/useScrollIntoView.d.ts +11 -0
  310. package/build/hooks/useSwipeGesture/index.d.ts +1 -0
  311. package/build/hooks/useSwipeGesture/useSwipeGesture.d.ts +27 -0
  312. package/package.json +83 -0
  313. package/src/components/navigation/styles/link.css +152 -0
  314. package/src/components/navigation/styles/link.min.css +1 -0
  315. package/src/components/navigation/styles/link.scss +138 -0
  316. package/src/core/jkl/_colors.scss +26 -0
  317. package/src/core/jkl/_convert.scss +96 -0
  318. package/src/core/jkl/_helpers.scss +20 -0
  319. package/src/core/jkl/_index.scss +18 -0
  320. package/src/core/jkl/_legacy-tokens.scss +22 -0
  321. package/src/core/jkl/_motion.scss +62 -0
  322. package/src/core/jkl/_navigation.scss +9 -0
  323. package/src/core/jkl/_ornaments.scss +26 -0
  324. package/src/core/jkl/_reset.scss +43 -0
  325. package/src/core/jkl/_responsive-units.scss +30 -0
  326. package/src/core/jkl/_screenreader.scss +59 -0
  327. package/src/core/jkl/_screens.scss +135 -0
  328. package/src/core/jkl/_shadows.scss +25 -0
  329. package/src/core/jkl/_spacing.scss +210 -0
  330. package/src/core/jkl/_theme.scss +144 -0
  331. package/src/core/jkl/_tokens.scss +148 -0
  332. package/src/core/jkl/_typography.scss +327 -0
  333. package/src/core/jkl/_underline.scss +16 -0
  334. package/src/core/jkl/_z-index.scss +23 -0
  335. package/src/core/styles/_color-tokens.scss +75 -0
  336. package/src/core/styles/_headings.scss +29 -0
  337. package/src/core/styles/_index.scss +10 -0
  338. package/src/core/styles/_legacy-tokens.scss +26 -0
  339. package/src/core/styles/_normalize.scss +250 -0
  340. package/src/core/styles/_paragraphs.scss +16 -0
  341. package/src/core/styles/_reset.scss +66 -0
  342. package/src/core/styles/_screen-reader.scss +9 -0
  343. package/src/core/styles/_spacing.scss +75 -0
  344. package/src/core/styles/_tokens.scss +114 -0
  345. package/src/core/styles/core.css +1614 -0
  346. package/src/core/styles/core.min.css +1 -0
  347. package/src/core/styles/core.scss +71 -0
  348. package/src/core/styles/vind/_flex.scss +113 -0
  349. package/src/core/styles/vind/_font.scss +19 -0
  350. package/src/core/styles/vind/_margin.scss +43 -0
  351. package/src/core/styles/vind/_padding.scss +43 -0
  352. package/src/core/styles/vind/_space-between.scss +13 -0
  353. package/src/core/styles/vind/_typography.scss +47 -0
  354. package/src/core/styles/vind/_vind.scss +6 -0
  355. package/src/core/styles/vind.css +1742 -0
  356. package/src/core/styles/vind.min.css +1 -0
  357. package/src/core/styles/vind.scss +3 -0
  358. package/src/core/tokens.less +196 -0
@@ -0,0 +1,148 @@
1
+ /**
2
+ * Do not edit directly
3
+ * Generated on Tue, 10 Sep 2024 05:21:22 GMT
4
+ */
5
+
6
+ $color-brand-snohvit: #f9f9f9;
7
+ $color-brand-varde: #e0dbd4;
8
+ $color-brand-granitt: #1b1917;
9
+ $color-brand-hvit: #ffffff;
10
+ $color-brand-svart: #000000;
11
+ $color-brand-skifer: #313030;
12
+ $color-brand-fjellgra: #444141;
13
+ $color-brand-stein: #636060;
14
+ $color-brand-svaberg: #c8c5c3;
15
+ $color-brand-dis: #ece9e5;
16
+ $color-brand-sand: #f4f2ef;
17
+ $color-functional-info: #d3d3f6;
18
+ $color-functional-info-dark: #a9a9ca;
19
+ $color-functional-success: #acd3b5;
20
+ $color-functional-success-dark: #94b79b;
21
+ $color-functional-warning: #efdd9e;
22
+ $color-functional-warning-dark: #decc8d;
23
+ $color-functional-error: #f6b3b3;
24
+ $color-functional-error-dark: #de9e9e;
25
+ $spacing-0: 0;
26
+ $spacing-2: 0.125rem;
27
+ $spacing-4: 0.25rem;
28
+ $spacing-8: 0.5rem;
29
+ $spacing-12: 0.75rem;
30
+ $spacing-16: 1rem;
31
+ $spacing-24: 1.5rem;
32
+ $spacing-32: 2rem;
33
+ $spacing-40: 2.5rem;
34
+ $spacing-64: 4rem;
35
+ $spacing-104: 6.5rem;
36
+ $spacing-168: 10.5rem;
37
+ $icon-weight-normal: 300;
38
+ $icon-weight-bold: 500;
39
+ $typography-weight-normal: 400;
40
+ $typography-weight-bold: 700;
41
+ $typography-font-size-16: 1rem;
42
+ $typography-font-size-18: 1.125rem;
43
+ $typography-font-size-20: 1.25rem;
44
+ $typography-font-size-21: 1.3125rem;
45
+ $typography-font-size-23: 1.4375rem;
46
+ $typography-font-size-25: 1.5625rem;
47
+ $typography-font-size-26: 1.625rem;
48
+ $typography-font-size-28: 1.75rem;
49
+ $typography-font-size-30: 1.875rem;
50
+ $typography-font-size-36: 2.25rem;
51
+ $typography-font-size-44: 2.75rem;
52
+ $typography-font-size-56: 3.5rem;
53
+ $typography-line-height-24: 1.5rem;
54
+ $typography-line-height-28: 1.75rem;
55
+ $typography-line-height-32: 2rem;
56
+ $typography-line-height-36: 2.25rem;
57
+ $typography-line-height-40: 2.5rem;
58
+ $typography-line-height-44: 2.75rem;
59
+ $typography-line-height-52: 3.25rem;
60
+ $typography-line-height-64: 4rem;
61
+ $typography-title-small-font-size: 2.25rem;
62
+ $typography-title-small-line-height: 2.75rem;
63
+ $typography-title-small-font-weight: 400;
64
+ $typography-title-base-font-size: 3.5rem;
65
+ $typography-title-base-line-height: 4rem;
66
+ $typography-title-base-font-weight: 400;
67
+ $typography-title-small-small-font-size: 1.875rem;
68
+ $typography-title-small-small-line-height: 2.25rem;
69
+ $typography-title-small-small-font-weight: 400;
70
+ $typography-title-small-base-font-size: 2.75rem;
71
+ $typography-title-small-base-line-height: 3.25rem;
72
+ $typography-title-small-base-font-weight: 400;
73
+ $typography-heading-1-small-font-size: 1.625rem;
74
+ $typography-heading-1-small-line-height: 2rem;
75
+ $typography-heading-1-small-font-weight: 400;
76
+ $typography-heading-1-base-font-size: 2.25rem;
77
+ $typography-heading-1-base-line-height: 2.75rem;
78
+ $typography-heading-1-base-font-weight: 400;
79
+ $typography-heading-2-small-font-size: 1.4375rem;
80
+ $typography-heading-2-small-line-height: 2rem;
81
+ $typography-heading-2-small-font-weight: 400;
82
+ $typography-heading-2-base-font-size: 1.75rem;
83
+ $typography-heading-2-base-line-height: 2.5rem;
84
+ $typography-heading-2-base-font-weight: 400;
85
+ $typography-heading-3-small-font-size: 1.3125rem;
86
+ $typography-heading-3-small-line-height: 1.75rem;
87
+ $typography-heading-3-small-font-weight: 700;
88
+ $typography-heading-3-base-font-size: 1.5625rem;
89
+ $typography-heading-3-base-line-height: 2rem;
90
+ $typography-heading-3-base-font-weight: 700;
91
+ $typography-heading-4-small-font-size: 1.125rem;
92
+ $typography-heading-4-small-line-height: 1.5rem;
93
+ $typography-heading-4-small-font-weight: 700;
94
+ $typography-heading-4-base-font-size: 1.3125rem;
95
+ $typography-heading-4-base-line-height: 1.75rem;
96
+ $typography-heading-4-base-font-weight: 700;
97
+ $typography-heading-5-small-font-size: 1rem;
98
+ $typography-heading-5-small-line-height: 1.5rem;
99
+ $typography-heading-5-small-font-weight: 700;
100
+ $typography-heading-5-base-font-size: 1rem;
101
+ $typography-heading-5-base-line-height: 1.5rem;
102
+ $typography-heading-5-base-font-weight: 700;
103
+ $typography-body-small-font-size: 1.125rem;
104
+ $typography-body-small-line-height: 1.75rem;
105
+ $typography-body-small-font-weight: 400;
106
+ $typography-body-base-font-size: 1.25rem;
107
+ $typography-body-base-line-height: 2rem;
108
+ $typography-body-base-font-weight: 400;
109
+ $typography-small-small-font-size: 1rem;
110
+ $typography-small-small-line-height: 1.5rem;
111
+ $typography-small-small-font-weight: 400;
112
+ $typography-small-base-font-size: 1rem;
113
+ $typography-small-base-line-height: 1.5rem;
114
+ $typography-small-base-font-weight: 400;
115
+
116
+ // Dynamiske variabler for farge, via referanse til CSS-variabler
117
+ $color-background-page: var(--jkl-color-background-page);
118
+ $color-background-page-variant: var(--jkl-color-background-page-variant);
119
+ $color-background-container: var(--jkl-color-background-container);
120
+ $color-background-container-low: var(--jkl-color-background-container-low);
121
+ $color-background-container-high: var(--jkl-color-background-container-high);
122
+ $color-background-container-inverted: var(--jkl-color-background-container-inverted);
123
+ $color-background-container-subdued: var(--jkl-color-background-container-subdued);
124
+ $color-background-input-base: var(--jkl-color-background-input-base);
125
+ $color-background-input-focus: var(--jkl-color-background-input-focus);
126
+ $color-background-action: var(--jkl-color-background-action);
127
+ $color-background-interactive: var(--jkl-color-background-interactive);
128
+ $color-background-interactive-hover: var(--jkl-color-background-interactive-hover);
129
+ $color-background-interactive-selected: var(--jkl-color-background-interactive-selected);
130
+ $color-background-alert-neutral: var(--jkl-color-background-alert-neutral);
131
+ $color-background-alert-info: var(--jkl-color-background-alert-info);
132
+ $color-background-alert-success: var(--jkl-color-background-alert-success);
133
+ $color-background-alert-warning: var(--jkl-color-background-alert-warning);
134
+ $color-background-alert-error: var(--jkl-color-background-alert-error);
135
+ $color-text-default: var(--jkl-color-text-default);
136
+ $color-text-subdued: var(--jkl-color-text-subdued);
137
+ $color-text-inverted: var(--jkl-color-text-inverted);
138
+ $color-text-on-action: var(--jkl-color-text-on-action);
139
+ $color-text-interactive: var(--jkl-color-text-interactive);
140
+ $color-text-interactive-hover: var(--jkl-color-text-interactive-hover);
141
+ $color-text-on-alert: var(--jkl-color-text-on-alert);
142
+ $color-border-action: var(--jkl-color-border-action);
143
+ $color-border-input: var(--jkl-color-border-input);
144
+ $color-border-input-focus: var(--jkl-color-border-input-focus);
145
+ $color-border-separator: var(--jkl-color-border-separator);
146
+ $color-border-separator-strong: var(--jkl-color-border-separator-strong);
147
+ $color-border-separator-hover: var(--jkl-color-border-separator-hover);
148
+ $color-border-subdued: var(--jkl-color-border-subdued);
@@ -0,0 +1,327 @@
1
+ @use "sass:string";
2
+ @use "sass:map";
3
+ @use "sass:list";
4
+ @use "screens";
5
+ @use "tokens" as *;
6
+
7
+ /// Tilsvarer 16px
8
+ /// @deprecated Bruk heller $typography-font-size-16
9
+ /// @type Number
10
+ $typography-font-size-1: $typography-font-size-16;
11
+
12
+ /// Tilsvarer 18px
13
+ /// @deprecated Bruk heller $typography-font-size-18
14
+ /// @type Number
15
+ $typography-font-size-2: $typography-font-size-18;
16
+
17
+ /// Tilsvarer 20px
18
+ /// @deprecated Bruk heller $typography-font-size-20
19
+ /// @type Number
20
+ $typography-font-size-3: $typography-font-size-20;
21
+
22
+ /// Tilsvarer 21px
23
+ /// @deprecated Bruk heller $typography-font-size-21
24
+ /// @type Number
25
+ $typography-font-size-4: $typography-font-size-21;
26
+
27
+ /// Tilsvarer 23px
28
+ /// @deprecated Bruk heller $typography-font-size-23
29
+ /// @type Number
30
+ $typography-font-size-5: $typography-font-size-23;
31
+
32
+ /// Tilsvarer 25px
33
+ /// @deprecated Bruk heller $typography-font-size-25
34
+ /// @type Number
35
+ $typography-font-size-6: $typography-font-size-25;
36
+
37
+ /// Tilsvarer 26px
38
+ /// @deprecated Bruk heller $typography-font-size-26
39
+ /// @type Number
40
+ $typography-font-size-7: $typography-font-size-26;
41
+
42
+ /// Tilsvarer 28px
43
+ /// @deprecated Bruk heller $typography-font-size-28
44
+ /// @type Number
45
+ $typography-font-size-8: $typography-font-size-28;
46
+
47
+ /// Tilsvarer 36px
48
+ /// @deprecated Bruk heller $typography-font-size-36
49
+ /// @type Number
50
+ $typography-font-size-9: $typography-font-size-36;
51
+
52
+ /// Tilsvarer 56px
53
+ /// @deprecated Bruk heller $typography-font-size-56
54
+ /// @type Number
55
+ $typography-font-size-10: $typography-font-size-56;
56
+
57
+ /// Tilsvarer 24px
58
+ /// @deprecated Bruk heller $typography-line-height-24
59
+ /// @type Number
60
+ $typography-line-height-1: $typography-line-height-24;
61
+
62
+ /// Tilsvarer 28px
63
+ /// @deprecated Bruk heller $typography-line-height-28
64
+ /// @type Number
65
+ $typography-line-height-2: $typography-line-height-28;
66
+
67
+ /// Tilsvarer 32px
68
+ /// @deprecated Bruk heller $typography-line-height-32
69
+ /// @type Number
70
+ $typography-line-height-3: $typography-line-height-32;
71
+
72
+ /// Tilsvarer 40px
73
+ /// @deprecated Bruk heller $typography-line-height-40
74
+ /// @type Number
75
+ $typography-line-height-4: $typography-line-height-40;
76
+
77
+ /// Tilsvarer 44px
78
+ /// @deprecated Bruk heller $typography-line-height-44
79
+ /// @type Number
80
+ $typography-line-height-5: $typography-line-height-44;
81
+
82
+ /// Tilsvarer 64px
83
+ /// @deprecated Bruk heller $typography-line-height-64
84
+ /// @type Number
85
+ $typography-line-height-6: $typography-line-height-64;
86
+
87
+ /// @access private - forwardes ikke ut av modulen, men er tilgjengelig ved direkteimport. KUN FOR INTERN BRUK I JØKUL.
88
+ $text-styles: (
89
+ "title": (
90
+ "small-screen": (
91
+ "font-size": $typography-title-small-font-size,
92
+ "line-height": $typography-title-small-line-height,
93
+ "font-weight": $typography-title-small-font-weight,
94
+ "--jkl-icon-weight": $icon-weight-normal,
95
+ ),
96
+ "large-screen": (
97
+ "font-size": $typography-title-base-font-size,
98
+ "line-height": $typography-title-base-line-height,
99
+ "font-weight": $typography-title-base-font-weight,
100
+ "--jkl-icon-weight": $icon-weight-normal,
101
+ ),
102
+ ),
103
+ "title-small": (
104
+ "small-screen": (
105
+ "font-size": $typography-title-small-small-font-size,
106
+ "line-height": $typography-title-small-small-line-height,
107
+ "font-weight": $typography-title-small-small-font-weight,
108
+ "--jkl-icon-weight": $icon-weight-normal,
109
+ ),
110
+ "large-screen": (
111
+ "font-size": $typography-title-small-base-font-size,
112
+ "line-height": $typography-title-small-base-line-height,
113
+ "font-weight": $typography-title-small-base-font-weight,
114
+ "--jkl-icon-weight": $icon-weight-normal,
115
+ ),
116
+ ),
117
+ "heading-1": (
118
+ "small-screen": (
119
+ "font-size": $typography-heading-1-small-font-size,
120
+ "line-height": $typography-heading-1-small-line-height,
121
+ "font-weight": $typography-heading-1-small-font-weight,
122
+ "--jkl-icon-weight": $icon-weight-normal,
123
+ ),
124
+ "large-screen": (
125
+ "font-size": $typography-heading-1-base-font-size,
126
+ "line-height": $typography-heading-1-base-line-height,
127
+ "font-weight": $typography-heading-1-base-font-weight,
128
+ "--jkl-icon-weight": $icon-weight-normal,
129
+ ),
130
+ ),
131
+ "heading-2": (
132
+ "small-screen": (
133
+ "font-size": $typography-heading-2-small-font-size,
134
+ "line-height": $typography-heading-2-small-line-height,
135
+ "font-weight": $typography-heading-2-small-font-weight,
136
+ "--jkl-icon-weight": $icon-weight-normal,
137
+ ),
138
+ "large-screen": (
139
+ "font-size": $typography-heading-2-base-font-size,
140
+ "line-height": $typography-heading-2-base-line-height,
141
+ "font-weight": $typography-heading-2-base-font-weight,
142
+ "--jkl-icon-weight": $icon-weight-normal,
143
+ ),
144
+ ),
145
+ "heading-3": (
146
+ "small-screen": (
147
+ "font-size": $typography-heading-3-small-font-size,
148
+ "line-height": $typography-heading-3-small-line-height,
149
+ "font-weight": $typography-heading-3-small-font-weight,
150
+ "--jkl-icon-weight": $icon-weight-bold,
151
+ ),
152
+ "large-screen": (
153
+ "font-size": $typography-heading-3-base-font-size,
154
+ "line-height": $typography-heading-3-base-line-height,
155
+ "font-weight": $typography-heading-3-base-font-weight,
156
+ "--jkl-icon-weight": $icon-weight-bold,
157
+ ),
158
+ ),
159
+ "heading-4": (
160
+ "small-screen": (
161
+ "font-size": $typography-heading-4-small-font-size,
162
+ "line-height": $typography-heading-4-small-line-height,
163
+ "font-weight": $typography-heading-4-small-font-weight,
164
+ "--jkl-icon-weight": $icon-weight-bold,
165
+ ),
166
+ "large-screen": (
167
+ "font-size": $typography-heading-4-base-font-size,
168
+ "line-height": $typography-heading-4-base-line-height,
169
+ "font-weight": $typography-heading-4-base-font-weight,
170
+ "--jkl-icon-weight": $icon-weight-bold,
171
+ ),
172
+ ),
173
+ "heading-5": (
174
+ "small-screen": (
175
+ "font-size": $typography-heading-5-small-font-size,
176
+ "line-height": $typography-heading-5-small-line-height,
177
+ "font-weight": $typography-heading-5-small-font-weight,
178
+ "--jkl-icon-weight": $icon-weight-bold,
179
+ ),
180
+ "large-screen": (
181
+ "font-size": $typography-heading-5-base-font-size,
182
+ "line-height": $typography-heading-5-base-line-height,
183
+ "font-weight": $typography-heading-5-base-font-weight,
184
+ "--jkl-icon-weight": $icon-weight-bold,
185
+ ),
186
+ ),
187
+ "body": (
188
+ "small-screen": (
189
+ "font-size": $typography-body-small-font-size,
190
+ "line-height": $typography-body-small-line-height,
191
+ "font-weight": $typography-body-small-font-weight,
192
+ "--jkl-icon-weight": $icon-weight-normal,
193
+ ),
194
+ "large-screen": (
195
+ "font-size": $typography-body-base-font-size,
196
+ "line-height": $typography-body-base-line-height,
197
+ "font-weight": $typography-body-base-font-weight,
198
+ "--jkl-icon-weight": $icon-weight-normal,
199
+ ),
200
+ ),
201
+ "small": (
202
+ "small-screen": (
203
+ "font-size": $typography-small-small-font-size,
204
+ "line-height": $typography-small-small-line-height,
205
+ "font-weight": $typography-small-small-font-weight,
206
+ "--jkl-icon-weight": $icon-weight-normal,
207
+ ),
208
+ "large-screen": (
209
+ "font-size": $typography-small-base-font-size,
210
+ "line-height": $typography-small-base-line-height,
211
+ "font-weight": $typography-small-base-font-weight,
212
+ "--jkl-icon-weight": $icon-weight-normal,
213
+ ),
214
+ ),
215
+ );
216
+
217
+ /// Gir deg responsive font-size, line-height og font-weight basert på navnet på typografien.
218
+ /// Du kan overstyre standardverdier ved å bruke `@content`. Dette er ment som en "escape hatch".
219
+ /// Ikke tukle med typografiskalaen med mindre du har en god grunn til det.
220
+ /// @param {"title" | "title-small" | "heading-1" | "heading-2" | "heading-3" | "heading-4" | "heading-5" | "body" | "small" | "title/large-screen" | "heading-1/large-screen" | "heading-2/large-screen" | "heading-3/large-screen" | "heading-4/large-screen" | "heading-5/large-screen" | "body/large-screen" | "small/large-screen" | "title/small-screen" | "heading-1/small-screen" | "heading-2/small-screen" | "heading-3/small-screen" | "heading-4/small-screen" | "heading-5/small-screen" | "body/small-screen" | "small/small-screen"} $style-name - Ønsket stilnavn. Støtter å hente small-screen og large-screen også, om du trenger stilene fra en spesifik skjermstørrelse.
221
+ /// @content Plasseres alltid etter mixinen har satt sine verdier, slik at du kan velge å overstyre deler av dem.
222
+ /// @example
223
+ /// .class {
224
+ /// @include jkl.text-style("body");
225
+ /// }
226
+ /// @example
227
+ /// .bold {
228
+ /// @include jkl.text-style("body") {
229
+ /// font-weight: jkl.$typography-weight-bold;
230
+ /// }
231
+ /// }
232
+ @mixin text-style($style-name) {
233
+ // Separate style/variant into style and variant variables:
234
+ $start-index: string.index($style-name, "/") or 0;
235
+ $end-index: string.index($style-name, "/") or 9999999;
236
+ $style: string.slice($style-name, 0, $start-index - 1);
237
+ $variant: string.slice($style-name, $end-index + 1);
238
+
239
+ @if map.has-key($text-styles, $style) {
240
+ $variants: map.get($text-styles, $style);
241
+
242
+ @if string.length($variant) == 0 {
243
+ @each $property, $value in map.get($variants, "small-screen") {
244
+ #{$property}: $value;
245
+ }
246
+ @content;
247
+
248
+ // Styles heading-5 and small are the same size on small and large screens. Skip to generate less CSS.
249
+ @if $style != "small" and $style != "heading-5" {
250
+ @include screens.from-medium-device {
251
+ @each $property, $value in map.get($variants, "large-screen") {
252
+ #{$property}: $value;
253
+ }
254
+ @content;
255
+ }
256
+ }
257
+ } @else {
258
+ @if map.has-key($variants, $variant) {
259
+ @each $property, $value in map.get($variants, $variant) {
260
+ #{$property}: $value;
261
+ }
262
+ @content;
263
+ } @else {
264
+ @error "The text style #{$style} has no variant called #{$variant}. Try one of these: #{map.keys(map.get($new-text-styles, $style))}";
265
+ }
266
+ }
267
+ } @else {
268
+ @error "No text style with the name #{$style} was found. Try one of these: #{map.keys($new-text-styles)}";
269
+ }
270
+ }
271
+
272
+ /// Makes text bold without changing the space it takes up on screen.
273
+ /// Not perfect for all lengths of text, but close enough!
274
+ @mixin no-grow-bold {
275
+ --jkl-icon-weight: #{$icon-weight-bold};
276
+ font-weight: $typography-weight-bold;
277
+ letter-spacing: -0.014em;
278
+ }
279
+
280
+ /// Definer egne variabler for fontstørrelse basert på design tokens fra :root. Kan enkelt brukes med `use-font-variables`.
281
+ /// @param {String} $name - Navn på variablen. Postfixes med `-font-size`, `-line-height`, og `-font-weight`.
282
+ /// @param {"title" | "title-small" | "heading-1" | "heading-2" | "heading-3" | "heading-4" | "heading-5" | "body" | "small"} $level - Nivå i fontskalaen.
283
+ /// @output - CSS-variabler fro font-size, line-height, og font-weight.
284
+ /// @see use-font-variables
285
+ /// @example
286
+ /// @include jkl.declare-font-variables("jkl-accordion-title", "body");
287
+ /// @example
288
+ /// @include jkl.use-font-variables("jkl-accordion-title");
289
+ @mixin declare-font-variables($name, $level) {
290
+ --#{$name}-font-size: var(--jkl-#{$level}-font-size);
291
+ --#{$name}-line-height: var(--jkl-#{$level}-line-height);
292
+ --#{$name}-font-weight: var(--jkl-#{$level}-font-weight);
293
+ }
294
+
295
+ /// Ta i bruk variabler du har laget med `declare-font-variables`.
296
+ /// @param {String} $name - Navn på variablen. Postfixes med `-font-size`, `-line-height`, og `-font-weight`.
297
+ /// @output - CSS som setter font-size, line-height, og font-weight basert på CSS-variabler som følger standard format fra `declare-font-variables`.
298
+ /// @see declare-font-variables
299
+ /// @example
300
+ /// @include jkl.use-font-variables("jkl-accordion-title");
301
+ /// @example
302
+ /// @include jkl.declare-font-variables("jkl-accordion-title", "body");
303
+ @mixin use-font-variables($name) {
304
+ font-size: var(--#{$name}-font-size);
305
+ line-height: var(--#{$name}-line-height);
306
+ font-weight: var(--#{$name}-font-weight);
307
+ }
308
+
309
+ $_valid-font-family-values: ("Fremtind Grotesk", "Fremtind Grotesk Display", "Fremtind Grotesk Mono");
310
+
311
+ /// Hjelper sette riktig remse med fallback-fonts for Fremtind Grotesk, Fremtind Grotesk Display, og Fremtind Grotesk Mono.
312
+ /// @param {"Fremtind Grotesk" | "Fremtind Grotesk Mono" | "Fremtind Grotesk Display"} $font - Regular justerer seg automatisk til italic og bold basert på font-style og font-weight. Display og Mono er adskilte fontfamilier.
313
+ /// @output - Ønsket fontfamilie med justert fallbackfont.
314
+ @mixin use-font-family($font) {
315
+ @if not list.index($_valid-font-family-values, $font) {
316
+ @error "#{$font} will not be used for font-family. Valid options are: #{$_valid-font-family-values}.";
317
+ }
318
+
319
+ @if $font == "Fremtind Grotesk Mono" {
320
+ font-family: "Fremtind Grotesk Mono", "Adjusted Courier New Fallback", -apple-system, BlinkMacSystemFont,
321
+ monospace;
322
+ } @else if $font == "Fremtind Grotesk Display" {
323
+ font-family: "Fremtind Grotesk Display", "Adjusted Arial Display Fallback", Arial, sans-serif;
324
+ } @else {
325
+ font-family: "Fremtind Grotesk", "Adjusted Arial Fallback", Arial, sans-serif;
326
+ }
327
+ }
@@ -0,0 +1,16 @@
1
+ @use "responsive-units" as ru;
2
+
3
+ /// Gir deg en understrek-effekt med box-shadow
4
+ /// @param {Color} $color - Standardfarge, og farge ved hover
5
+ /// @param {Color} $focus-color - Farge ved tastaturfokus
6
+ @mixin underline-color($color, $focus-color) {
7
+ box-shadow: inset 0 ru.rem(-2px) 0 0 $color;
8
+
9
+ html:not([data-mousenavigation]) &:focus {
10
+ box-shadow: inset 0 ru.rem(-4px) 0 0 $focus-color;
11
+ }
12
+
13
+ &:hover {
14
+ box-shadow: inset 0 ru.rem(-4px) 0 0 $color;
15
+ }
16
+ }
@@ -0,0 +1,23 @@
1
+ /// @type Number
2
+ $z-index--floating: 10000;
3
+
4
+ /// @type Number
5
+ $z-index--modal: 9000;
6
+
7
+ /// @type Number
8
+ $z-index--overlay: 8000;
9
+
10
+ /// @type Number
11
+ $z-index--dropdown: 7000;
12
+
13
+ /// @type Number
14
+ $z-index--header: 6000;
15
+
16
+ /// @type Number
17
+ $z-index--footer: 5000;
18
+
19
+ /// @type Number
20
+ $z-index--hidden: -1;
21
+
22
+ /// @type Number
23
+ $z-index--overflow-hidden: -1;
@@ -0,0 +1,75 @@
1
+ /**
2
+ * Do not edit directly
3
+ * Generated on Tue, 10 Sep 2024 05:21:22 GMT
4
+ */
5
+
6
+ @use "../jkl";
7
+
8
+ @include jkl.light-mode-variables {
9
+ --jkl-color-background-page: #{jkl.$color-brand-sand};
10
+ --jkl-color-background-page-variant: #{jkl.$color-brand-snohvit};
11
+ --jkl-color-background-container: #{jkl.$color-brand-snohvit};
12
+ --jkl-color-background-container-low: #{jkl.$color-brand-dis};
13
+ --jkl-color-background-container-high: #{jkl.$color-brand-hvit};
14
+ --jkl-color-background-container-inverted: #{jkl.$color-brand-granitt};
15
+ --jkl-color-background-container-subdued: #{jkl.$color-brand-svaberg};
16
+ --jkl-color-background-input-base: rgba(0, 0, 0, 0);
17
+ --jkl-color-background-input-focus: #{jkl.$color-brand-hvit};
18
+ --jkl-color-background-action: #{jkl.$color-brand-granitt};
19
+ --jkl-color-background-interactive: rgba(0, 0, 0, 0);
20
+ --jkl-color-background-interactive-hover: #{jkl.$color-brand-dis};
21
+ --jkl-color-background-interactive-selected: #{jkl.$color-brand-varde};
22
+ --jkl-color-background-alert-neutral: #{jkl.$color-brand-varde};
23
+ --jkl-color-background-alert-info: #{jkl.$color-functional-info};
24
+ --jkl-color-background-alert-success: #{jkl.$color-functional-success};
25
+ --jkl-color-background-alert-warning: #{jkl.$color-functional-warning};
26
+ --jkl-color-background-alert-error: #{jkl.$color-functional-error};
27
+ --jkl-color-text-default: #{jkl.$color-brand-granitt};
28
+ --jkl-color-text-subdued: #{jkl.$color-brand-stein};
29
+ --jkl-color-text-inverted: #{jkl.$color-brand-snohvit};
30
+ --jkl-color-text-on-action: #{jkl.$color-brand-snohvit};
31
+ --jkl-color-text-interactive: #{jkl.$color-brand-granitt};
32
+ --jkl-color-text-interactive-hover: #{jkl.$color-brand-stein};
33
+ --jkl-color-text-on-alert: #{jkl.$color-brand-granitt};
34
+ --jkl-color-border-action: #{jkl.$color-brand-granitt};
35
+ --jkl-color-border-input: #{jkl.$color-brand-stein};
36
+ --jkl-color-border-input-focus: #{jkl.$color-brand-granitt};
37
+ --jkl-color-border-separator: #{jkl.$color-brand-svaberg};
38
+ --jkl-color-border-separator-strong: #{jkl.$color-brand-stein};
39
+ --jkl-color-border-separator-hover: #{jkl.$color-brand-granitt};
40
+ --jkl-color-border-subdued: #{jkl.$color-brand-svaberg};
41
+ }
42
+ @include jkl.dark-mode-variables {
43
+ --jkl-color-background-page: #{jkl.$color-brand-granitt};
44
+ --jkl-color-background-page-variant: #{jkl.$color-brand-granitt};
45
+ --jkl-color-background-container: #{jkl.$color-brand-skifer};
46
+ --jkl-color-background-container-low: #{jkl.$color-brand-svart};
47
+ --jkl-color-background-container-high: #{jkl.$color-brand-skifer};
48
+ --jkl-color-background-container-inverted: #{jkl.$color-brand-snohvit};
49
+ --jkl-color-background-container-subdued: #{jkl.$color-brand-stein};
50
+ --jkl-color-background-input-base: rgba(0, 0, 0, 0);
51
+ --jkl-color-background-input-focus: #{jkl.$color-brand-skifer};
52
+ --jkl-color-background-action: #{jkl.$color-brand-snohvit};
53
+ --jkl-color-background-interactive: rgba(0, 0, 0, 0);
54
+ --jkl-color-background-interactive-hover: #{jkl.$color-brand-fjellgra};
55
+ --jkl-color-background-interactive-selected: #{jkl.$color-brand-stein};
56
+ --jkl-color-background-alert-neutral: #{jkl.$color-brand-varde};
57
+ --jkl-color-background-alert-info: #{jkl.$color-functional-info-dark};
58
+ --jkl-color-background-alert-success: #{jkl.$color-functional-success-dark};
59
+ --jkl-color-background-alert-warning: #{jkl.$color-functional-warning-dark};
60
+ --jkl-color-background-alert-error: #{jkl.$color-functional-error-dark};
61
+ --jkl-color-text-default: #{jkl.$color-brand-snohvit};
62
+ --jkl-color-text-subdued: #{jkl.$color-brand-svaberg};
63
+ --jkl-color-text-inverted: #{jkl.$color-brand-granitt};
64
+ --jkl-color-text-on-action: #{jkl.$color-brand-granitt};
65
+ --jkl-color-text-interactive: #{jkl.$color-brand-snohvit};
66
+ --jkl-color-text-interactive-hover: #{jkl.$color-brand-svaberg};
67
+ --jkl-color-text-on-alert: #{jkl.$color-brand-granitt};
68
+ --jkl-color-border-action: #{jkl.$color-brand-snohvit};
69
+ --jkl-color-border-input: #{jkl.$color-brand-svaberg};
70
+ --jkl-color-border-input-focus: #{jkl.$color-brand-snohvit};
71
+ --jkl-color-border-separator: #{jkl.$color-brand-stein};
72
+ --jkl-color-border-separator-strong: #{jkl.$color-brand-svaberg};
73
+ --jkl-color-border-separator-hover: #{jkl.$color-brand-snohvit};
74
+ --jkl-color-border-subdued: #{jkl.$color-brand-stein};
75
+ }
@@ -0,0 +1,29 @@
1
+ @use "../jkl";
2
+
3
+ .jkl-title {
4
+ @include jkl.text-style("title");
5
+ }
6
+
7
+ .jkl-title-small {
8
+ @include jkl.text-style("title-small");
9
+ }
10
+
11
+ .jkl-heading-1 {
12
+ @include jkl.text-style("heading-1");
13
+ }
14
+
15
+ .jkl-heading-2 {
16
+ @include jkl.text-style("heading-2");
17
+ }
18
+
19
+ .jkl-heading-3 {
20
+ @include jkl.text-style("heading-3");
21
+ }
22
+
23
+ .jkl-heading-4 {
24
+ @include jkl.text-style("heading-4");
25
+ }
26
+
27
+ .jkl-heading-5 {
28
+ @include jkl.text-style("heading-5");
29
+ }
@@ -0,0 +1,10 @@
1
+ @forward "normalize";
2
+ @forward "reset";
3
+
4
+ @forward "tokens";
5
+ @forward "legacy-tokens";
6
+ @forward "color-tokens";
7
+ @forward "headings";
8
+ @forward "paragraphs";
9
+ @forward "spacing";
10
+ @forward "screen-reader";
@@ -0,0 +1,26 @@
1
+ /**
2
+ * Do not edit directly
3
+ * Generated on Tue, 10 Sep 2024 05:21:22 GMT
4
+ */
5
+
6
+ :root {
7
+ --jkl-color-svart: #000000;
8
+ --jkl-color-granitt: #1b1917;
9
+ --jkl-color-skifer: #313030;
10
+ --jkl-color-fjellgra: #444141;
11
+ --jkl-color-stein: #636060;
12
+ --jkl-color-svaberg: #c8c5c3;
13
+ --jkl-color-varde: #e0dbd4;
14
+ --jkl-color-dis: #ece9e5;
15
+ --jkl-color-sand: #f4f2ef;
16
+ --jkl-color-snohvit: #f9f9f9;
17
+ --jkl-color-hvit: #ffffff;
18
+ --jkl-color-suksess: #acd3b5;
19
+ --jkl-color-suksess-dark: #94b79b;
20
+ --jkl-color-feil: #f6b3b3;
21
+ --jkl-color-feil-dark: #de9e9e;
22
+ --jkl-color-info: #d3d3f6;
23
+ --jkl-color-info-dark: #a9a9ca;
24
+ --jkl-color-advarsel: #efdd9e;
25
+ --jkl-color-advarsel-dark: #decc8d;
26
+ }