@fremtind/jokul 0.8.1 → 0.10.0
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.
- package/build/NativeSelect-DSmX3GZo.cjs +2 -0
- package/build/NativeSelect-DSmX3GZo.cjs.map +1 -0
- package/build/NativeSelect-EidDABsT.js +2 -0
- package/build/NativeSelect-EidDABsT.js.map +1 -0
- package/build/build-stats.html +1 -1
- package/build/cjs/components/accordion/Accordion.js +2 -0
- package/build/cjs/components/accordion/Accordion.js.map +1 -0
- package/build/cjs/components/accordion/AccordionItem.js +2 -0
- package/build/cjs/components/accordion/AccordionItem.js.map +1 -0
- package/build/cjs/components/accordion/index.js +2 -0
- package/build/cjs/components/accordion/index.js.map +1 -0
- package/build/cjs/components/breadcrumb/Breadcrumb.js +2 -0
- package/build/cjs/components/breadcrumb/Breadcrumb.js.map +1 -0
- package/build/cjs/components/breadcrumb/BreadcrumbItem.js +2 -0
- package/build/cjs/components/breadcrumb/BreadcrumbItem.js.map +1 -0
- package/build/cjs/components/breadcrumb/index.js +2 -0
- package/build/cjs/components/breadcrumb/index.js.map +1 -0
- package/build/cjs/components/button/Button.js +2 -0
- package/build/cjs/components/button/Button.js.map +1 -0
- package/build/cjs/components/button/index.js +2 -0
- package/build/cjs/components/button/index.js.map +1 -0
- package/build/cjs/components/button/types.js +2 -0
- package/build/cjs/components/button/types.js.map +1 -0
- package/build/cjs/components/checkbox/Checkbox.js +2 -0
- package/build/cjs/components/checkbox/Checkbox.js.map +1 -0
- package/build/cjs/components/checkbox/index.js +2 -0
- package/build/cjs/components/checkbox/index.js.map +1 -0
- package/build/cjs/components/combobox/Combobox.js +2 -0
- package/build/cjs/components/combobox/Combobox.js.map +1 -0
- package/build/cjs/components/combobox/index.js +2 -0
- package/build/cjs/components/combobox/index.js.map +1 -0
- package/build/cjs/components/cookie-consent/CookieConsent.js +2 -0
- package/build/cjs/components/cookie-consent/CookieConsent.js.map +1 -0
- package/build/cjs/components/cookie-consent/CookieConsentContext.js +2 -0
- package/build/cjs/components/cookie-consent/CookieConsentContext.js.map +1 -0
- package/build/cjs/components/cookie-consent/CookieConsentModal.js +2 -0
- package/build/cjs/components/cookie-consent/CookieConsentModal.js.map +1 -0
- package/build/cjs/components/cookie-consent/consents/CustomConsents.js +2 -0
- package/build/cjs/components/cookie-consent/consents/CustomConsents.js.map +1 -0
- package/build/cjs/components/cookie-consent/consents/DefaultConsents.js +2 -0
- package/build/cjs/components/cookie-consent/consents/DefaultConsents.js.map +1 -0
- package/build/cjs/components/cookie-consent/consents/RequirementCheckbox.js +2 -0
- package/build/cjs/components/cookie-consent/consents/RequirementCheckbox.js.map +1 -0
- package/build/cjs/components/cookie-consent/cookieConsentUtils.js +2 -0
- package/build/cjs/components/cookie-consent/cookieConsentUtils.js.map +1 -0
- package/build/cjs/components/cookie-consent/index.js +2 -0
- package/build/cjs/components/cookie-consent/index.js.map +1 -0
- package/build/cjs/components/cookie-consent/types.js +2 -0
- package/build/cjs/components/cookie-consent/types.js.map +1 -0
- package/build/cjs/components/datepicker/DatePicker.js +2 -0
- package/build/cjs/components/datepicker/DatePicker.js.map +1 -0
- package/build/cjs/components/datepicker/index.js +2 -0
- package/build/cjs/components/datepicker/index.js.map +1 -0
- package/build/cjs/components/datepicker/internal/Calendar.js +2 -0
- package/build/cjs/components/datepicker/internal/Calendar.js.map +1 -0
- package/build/cjs/components/datepicker/internal/calendarReducer.js +2 -0
- package/build/cjs/components/datepicker/internal/calendarReducer.js.map +1 -0
- package/build/cjs/components/datepicker/internal/useCalendar.js +2 -0
- package/build/cjs/components/datepicker/internal/useCalendar.js.map +1 -0
- package/build/cjs/components/datepicker/internal/utils.js +2 -0
- package/build/cjs/components/datepicker/internal/utils.js.map +1 -0
- package/build/cjs/components/datepicker/types.js +2 -0
- package/build/cjs/components/datepicker/types.js.map +1 -0
- package/build/cjs/components/datepicker/utils.js +2 -0
- package/build/cjs/components/datepicker/utils.js.map +1 -0
- package/build/cjs/components/datepicker/validation.js +2 -0
- package/build/cjs/components/datepicker/validation.js.map +1 -0
- package/build/cjs/components/index.js +1 -1
- package/build/cjs/components/input-group/FieldGroup.js +1 -1
- package/build/cjs/components/input-group/FieldGroup.js.map +1 -1
- package/build/cjs/components/input-group/InputGroup.js +1 -1
- package/build/cjs/components/input-group/InputGroup.js.map +1 -1
- package/build/cjs/components/input-group/Label.js +1 -1
- package/build/cjs/components/input-group/Label.js.map +1 -1
- package/build/cjs/components/input-group/SupportLabel.js +1 -1
- package/build/cjs/components/input-group/SupportLabel.js.map +1 -1
- package/build/cjs/components/list/List.js +2 -0
- package/build/cjs/components/list/List.js.map +1 -0
- package/build/cjs/components/list/ListItem.js +2 -0
- package/build/cjs/components/list/ListItem.js.map +1 -0
- package/build/cjs/components/list/index.js +2 -0
- package/build/cjs/components/list/index.js.map +1 -0
- package/build/cjs/components/modal/Modal.js +2 -0
- package/build/cjs/components/modal/Modal.js.map +1 -0
- package/build/cjs/components/modal/index.js +2 -0
- package/build/cjs/components/modal/index.js.map +1 -0
- package/build/cjs/components/modal/useModal.js +2 -0
- package/build/cjs/components/modal/useModal.js.map +1 -0
- package/build/cjs/components/radio-button/BaseRadioButton.js +2 -0
- package/build/cjs/components/radio-button/BaseRadioButton.js.map +1 -0
- package/build/cjs/components/radio-button/RadioButton.js +2 -0
- package/build/cjs/components/radio-button/RadioButton.js.map +1 -0
- package/build/cjs/components/radio-button/RadioButtonGroup.js +2 -0
- package/build/cjs/components/radio-button/RadioButtonGroup.js.map +1 -0
- package/build/cjs/components/radio-button/index.js +2 -0
- package/build/cjs/components/radio-button/index.js.map +1 -0
- package/build/cjs/components/radio-button/radioGroupContext.js +2 -0
- package/build/cjs/components/radio-button/radioGroupContext.js.map +1 -0
- package/build/cjs/components/select/NativeSelect.js +2 -0
- package/build/cjs/components/select/NativeSelect.js.map +1 -0
- package/build/cjs/components/select/Select.js +2 -0
- package/build/cjs/components/select/Select.js.map +1 -0
- package/build/cjs/components/select/index.js +2 -0
- package/build/cjs/components/select/index.js.map +1 -0
- package/build/cjs/components/select/select-utils.js +2 -0
- package/build/cjs/components/select/select-utils.js.map +1 -0
- package/build/cjs/components/tag/Tag.js +1 -1
- package/build/cjs/components/tag/Tag.js.map +1 -1
- package/build/cjs/components/text-input/BaseTextArea.js +2 -0
- package/build/cjs/components/text-input/BaseTextArea.js.map +1 -0
- package/build/cjs/components/text-input/BaseTextInput.js +2 -0
- package/build/cjs/components/text-input/BaseTextInput.js.map +1 -0
- package/build/cjs/components/text-input/TextArea.js +2 -0
- package/build/cjs/components/text-input/TextArea.js.map +1 -0
- package/build/cjs/components/text-input/TextInput.js +2 -0
- package/build/cjs/components/text-input/TextInput.js.map +1 -0
- package/build/cjs/components/text-input/index.js +2 -0
- package/build/cjs/components/text-input/index.js.map +1 -0
- package/build/cjs/components/tooltip/PopupTip.js +1 -1
- package/build/cjs/components/tooltip/PopupTip.js.map +1 -1
- package/build/cjs/components/tooltip/TooltipContent.js +1 -1
- package/build/cjs/components/tooltip/TooltipContent.js.map +1 -1
- package/build/cjs/components/tooltip/TooltipTrigger.js +1 -1
- package/build/cjs/components/tooltip/TooltipTrigger.js.map +1 -1
- package/build/cjs/index.js +1 -1
- package/build/components/accordion/Accordion.d.ts +8 -0
- package/build/components/accordion/AccordionItem.d.ts +10 -0
- package/build/components/accordion/index.d.ts +4 -0
- package/build/components/breadcrumb/Breadcrumb.d.ts +6 -0
- package/build/components/breadcrumb/BreadcrumbItem.d.ts +10 -0
- package/build/components/breadcrumb/index.d.ts +4 -0
- package/build/components/button/Button.d.ts +7 -0
- package/build/components/button/index.d.ts +2 -0
- package/build/components/button/types.d.ts +19 -0
- package/build/components/checkbox/Checkbox.d.ts +17 -0
- package/build/components/checkbox/index.d.ts +2 -0
- package/build/components/combobox/Combobox.d.ts +39 -0
- package/build/components/combobox/index.d.ts +2 -0
- package/build/components/cookie-consent/CookieConsent.d.ts +6 -0
- package/build/components/cookie-consent/CookieConsentContext.d.ts +48 -0
- package/build/components/cookie-consent/CookieConsentModal.d.ts +3 -0
- package/build/components/cookie-consent/consents/CustomConsents.d.ts +9 -0
- package/build/components/cookie-consent/consents/DefaultConsents.d.ts +9 -0
- package/build/components/cookie-consent/consents/RequirementCheckbox.d.ts +9 -0
- package/build/components/cookie-consent/cookieConsentUtils.d.ts +23 -0
- package/build/components/cookie-consent/index.d.ts +5 -0
- package/build/components/cookie-consent/types.d.ts +12 -0
- package/build/components/datepicker/DatePicker.d.ts +3 -0
- package/build/components/datepicker/index.d.ts +4 -0
- package/build/components/datepicker/internal/Calendar.d.ts +18 -0
- package/build/components/datepicker/internal/calendarReducer.d.ts +18 -0
- package/build/components/datepicker/internal/useCalendar.d.ts +59 -0
- package/build/components/datepicker/internal/utils.d.ts +167 -0
- package/build/components/datepicker/types.d.ts +269 -0
- package/build/components/datepicker/utils.d.ts +23 -0
- package/build/components/datepicker/validation.d.ts +11 -0
- package/build/components/index.d.ts +12 -0
- package/build/components/list/List.d.ts +8 -0
- package/build/components/list/ListItem.d.ts +8 -0
- package/build/components/list/index.d.ts +3 -0
- package/build/components/modal/Modal.d.ts +72 -0
- package/build/components/modal/index.d.ts +4 -0
- package/build/components/modal/useModal.d.ts +69 -0
- package/build/components/radio-button/BaseRadioButton.d.ts +10 -0
- package/build/components/radio-button/RadioButton.d.ts +15 -0
- package/build/components/radio-button/RadioButtonGroup.d.ts +24 -0
- package/build/components/radio-button/index.d.ts +6 -0
- package/build/components/radio-button/radioGroupContext.d.ts +16 -0
- package/build/components/select/NativeSelect.d.ts +19 -0
- package/build/components/select/Select.d.ts +53 -0
- package/build/components/select/index.d.ts +4 -0
- package/build/components/select/select-utils.d.ts +2 -0
- package/build/components/text-input/BaseTextArea.d.ts +27 -0
- package/build/components/text-input/BaseTextInput.d.ts +34 -0
- package/build/components/text-input/TextArea.d.ts +6 -0
- package/build/components/text-input/TextInput.d.ts +9 -0
- package/build/components/text-input/index.d.ts +4 -0
- package/build/es/components/accordion/Accordion.js +2 -0
- package/build/es/components/accordion/Accordion.js.map +1 -0
- package/build/es/components/accordion/AccordionItem.js +2 -0
- package/build/es/components/accordion/AccordionItem.js.map +1 -0
- package/build/es/components/accordion/index.js +2 -0
- package/build/es/components/accordion/index.js.map +1 -0
- package/build/es/components/breadcrumb/Breadcrumb.js +2 -0
- package/build/es/components/breadcrumb/Breadcrumb.js.map +1 -0
- package/build/es/components/breadcrumb/BreadcrumbItem.js +2 -0
- package/build/es/components/breadcrumb/BreadcrumbItem.js.map +1 -0
- package/build/es/components/breadcrumb/index.js +2 -0
- package/build/es/components/breadcrumb/index.js.map +1 -0
- package/build/es/components/button/Button.js +2 -0
- package/build/es/components/button/Button.js.map +1 -0
- package/build/es/components/button/index.js +2 -0
- package/build/es/components/button/index.js.map +1 -0
- package/build/es/components/button/types.js +2 -0
- package/build/es/components/button/types.js.map +1 -0
- package/build/es/components/checkbox/Checkbox.js +2 -0
- package/build/es/components/checkbox/Checkbox.js.map +1 -0
- package/build/es/components/checkbox/index.js +2 -0
- package/build/es/components/checkbox/index.js.map +1 -0
- package/build/es/components/combobox/Combobox.js +2 -0
- package/build/es/components/combobox/Combobox.js.map +1 -0
- package/build/es/components/combobox/index.js +2 -0
- package/build/es/components/combobox/index.js.map +1 -0
- package/build/es/components/cookie-consent/CookieConsent.js +2 -0
- package/build/es/components/cookie-consent/CookieConsent.js.map +1 -0
- package/build/es/components/cookie-consent/CookieConsentContext.js +2 -0
- package/build/es/components/cookie-consent/CookieConsentContext.js.map +1 -0
- package/build/es/components/cookie-consent/CookieConsentModal.js +2 -0
- package/build/es/components/cookie-consent/CookieConsentModal.js.map +1 -0
- package/build/es/components/cookie-consent/consents/CustomConsents.js +2 -0
- package/build/es/components/cookie-consent/consents/CustomConsents.js.map +1 -0
- package/build/es/components/cookie-consent/consents/DefaultConsents.js +2 -0
- package/build/es/components/cookie-consent/consents/DefaultConsents.js.map +1 -0
- package/build/es/components/cookie-consent/consents/RequirementCheckbox.js +2 -0
- package/build/es/components/cookie-consent/consents/RequirementCheckbox.js.map +1 -0
- package/build/es/components/cookie-consent/cookieConsentUtils.js +2 -0
- package/build/es/components/cookie-consent/cookieConsentUtils.js.map +1 -0
- package/build/es/components/cookie-consent/index.js +2 -0
- package/build/es/components/cookie-consent/index.js.map +1 -0
- package/build/es/components/cookie-consent/types.js +2 -0
- package/build/es/components/cookie-consent/types.js.map +1 -0
- package/build/es/components/datepicker/DatePicker.js +2 -0
- package/build/es/components/datepicker/DatePicker.js.map +1 -0
- package/build/es/components/datepicker/index.js +2 -0
- package/build/es/components/datepicker/index.js.map +1 -0
- package/build/es/components/datepicker/internal/Calendar.js +2 -0
- package/build/es/components/datepicker/internal/Calendar.js.map +1 -0
- package/build/es/components/datepicker/internal/calendarReducer.js +2 -0
- package/build/es/components/datepicker/internal/calendarReducer.js.map +1 -0
- package/build/es/components/datepicker/internal/useCalendar.js +2 -0
- package/build/es/components/datepicker/internal/useCalendar.js.map +1 -0
- package/build/es/components/datepicker/internal/utils.js +2 -0
- package/build/es/components/datepicker/internal/utils.js.map +1 -0
- package/build/es/components/datepicker/types.js +2 -0
- package/build/es/components/datepicker/types.js.map +1 -0
- package/build/es/components/datepicker/utils.js +2 -0
- package/build/es/components/datepicker/utils.js.map +1 -0
- package/build/es/components/datepicker/validation.js +2 -0
- package/build/es/components/datepicker/validation.js.map +1 -0
- package/build/es/components/index.js +1 -1
- package/build/es/components/input-group/FieldGroup.js +1 -1
- package/build/es/components/input-group/FieldGroup.js.map +1 -1
- package/build/es/components/input-group/InputGroup.js +1 -1
- package/build/es/components/input-group/InputGroup.js.map +1 -1
- package/build/es/components/input-group/Label.js +1 -1
- package/build/es/components/input-group/Label.js.map +1 -1
- package/build/es/components/input-group/SupportLabel.js +1 -1
- package/build/es/components/input-group/SupportLabel.js.map +1 -1
- package/build/es/components/list/List.js +2 -0
- package/build/es/components/list/List.js.map +1 -0
- package/build/es/components/list/ListItem.js +2 -0
- package/build/es/components/list/ListItem.js.map +1 -0
- package/build/es/components/list/index.js +2 -0
- package/build/es/components/list/index.js.map +1 -0
- package/build/es/components/modal/Modal.js +2 -0
- package/build/es/components/modal/Modal.js.map +1 -0
- package/build/es/components/modal/index.js +2 -0
- package/build/es/components/modal/index.js.map +1 -0
- package/build/es/components/modal/useModal.js +2 -0
- package/build/es/components/modal/useModal.js.map +1 -0
- package/build/es/components/radio-button/BaseRadioButton.js +2 -0
- package/build/es/components/radio-button/BaseRadioButton.js.map +1 -0
- package/build/es/components/radio-button/RadioButton.js +2 -0
- package/build/es/components/radio-button/RadioButton.js.map +1 -0
- package/build/es/components/radio-button/RadioButtonGroup.js +2 -0
- package/build/es/components/radio-button/RadioButtonGroup.js.map +1 -0
- package/build/es/components/radio-button/index.js +2 -0
- package/build/es/components/radio-button/index.js.map +1 -0
- package/build/es/components/radio-button/radioGroupContext.js +2 -0
- package/build/es/components/radio-button/radioGroupContext.js.map +1 -0
- package/build/es/components/select/NativeSelect.js +2 -0
- package/build/es/components/select/NativeSelect.js.map +1 -0
- package/build/es/components/select/Select.js +2 -0
- package/build/es/components/select/Select.js.map +1 -0
- package/build/es/components/select/index.js +2 -0
- package/build/es/components/select/index.js.map +1 -0
- package/build/es/components/select/select-utils.js +2 -0
- package/build/es/components/select/select-utils.js.map +1 -0
- package/build/es/components/tag/Tag.js +1 -1
- package/build/es/components/tag/Tag.js.map +1 -1
- package/build/es/components/text-input/BaseTextArea.js +2 -0
- package/build/es/components/text-input/BaseTextArea.js.map +1 -0
- package/build/es/components/text-input/BaseTextInput.js +2 -0
- package/build/es/components/text-input/BaseTextInput.js.map +1 -0
- package/build/es/components/text-input/TextArea.js +2 -0
- package/build/es/components/text-input/TextArea.js.map +1 -0
- package/build/es/components/text-input/TextInput.js +2 -0
- package/build/es/components/text-input/TextInput.js.map +1 -0
- package/build/es/components/text-input/index.js +2 -0
- package/build/es/components/text-input/index.js.map +1 -0
- package/build/es/components/tooltip/PopupTip.js +1 -1
- package/build/es/components/tooltip/PopupTip.js.map +1 -1
- package/build/es/components/tooltip/TooltipContent.js +1 -1
- package/build/es/components/tooltip/TooltipContent.js.map +1 -1
- package/build/es/components/tooltip/TooltipTrigger.js +1 -1
- package/build/es/components/tooltip/TooltipTrigger.js.map +1 -1
- package/build/es/index.js +1 -1
- package/build/hooks/useAriaLiveRegion/useAriaLiveRegion.d.ts +1 -1
- package/package.json +31 -4
- package/src/components/accordion/styles/_index.scss +1 -0
- package/src/components/accordion/styles/accordion.css +166 -0
- package/src/components/accordion/styles/accordion.min.css +1 -0
- package/src/components/accordion/styles/accordion.scss +147 -0
- package/src/components/breadcrumb/styles/_index.scss +1 -0
- package/src/components/breadcrumb/styles/breadcrumb.css +29 -0
- package/src/components/breadcrumb/styles/breadcrumb.min.css +1 -0
- package/src/components/breadcrumb/styles/breadcrumb.scss +34 -0
- package/src/components/button/styles/_index.scss +1 -0
- package/src/components/button/styles/button.css +251 -0
- package/src/components/button/styles/button.min.css +1 -0
- package/src/components/button/styles/button.scss +294 -0
- package/src/components/checkbox/styles/_index.scss +1 -0
- package/src/components/checkbox/styles/checkbox.css +191 -0
- package/src/components/checkbox/styles/checkbox.min.css +1 -0
- package/src/components/checkbox/styles/checkbox.scss +229 -0
- package/src/components/combobox/styles/_index.scss +1 -0
- package/src/components/combobox/styles/combobox.css +337 -0
- package/src/components/combobox/styles/combobox.min.css +1 -0
- package/src/components/combobox/styles/combobox.scss +307 -0
- package/src/components/cookie-consent/styles/_index.scss +1 -0
- package/src/components/cookie-consent/styles/cookie-consent.css +94 -0
- package/src/components/cookie-consent/styles/cookie-consent.min.css +1 -0
- package/src/components/cookie-consent/styles/cookie-consent.scss +79 -0
- package/src/components/datepicker/styles/_calendar-date-button.scss +100 -0
- package/src/components/datepicker/styles/_calendar-navigation-dropdown.scss +53 -0
- package/src/components/datepicker/styles/_calendar-navigation.scss +54 -0
- package/src/components/datepicker/styles/_calendar-table.scss +27 -0
- package/src/components/datepicker/styles/_calendar.scss +68 -0
- package/src/components/datepicker/styles/_index.scss +1 -0
- package/src/components/datepicker/styles/datepicker.css +453 -0
- package/src/components/datepicker/styles/datepicker.min.css +1 -0
- package/src/components/datepicker/styles/datepicker.scss +63 -0
- package/src/components/list/styles/_index.scss +1 -0
- package/src/components/list/styles/list.css +128 -0
- package/src/components/list/styles/list.min.css +1 -0
- package/src/components/list/styles/list.scss +166 -0
- package/src/components/loader/styles/loader.css +6 -6
- package/src/components/loader/styles/loader.min.css +1 -1
- package/src/components/loader/styles/skeleton-loader.css +5 -5
- package/src/components/loader/styles/skeleton-loader.min.css +1 -1
- package/src/components/modal/styles/_index.scss +1 -0
- package/src/components/modal/styles/modal.css +115 -0
- package/src/components/modal/styles/modal.min.css +1 -0
- package/src/components/modal/styles/modal.scss +100 -0
- package/src/components/radio-button/styles/_index.scss +1 -0
- package/src/components/radio-button/styles/radio-button.css +180 -0
- package/src/components/radio-button/styles/radio-button.min.css +1 -0
- package/src/components/radio-button/styles/radio-button.scss +201 -0
- package/src/components/select/styles/_index.scss +1 -0
- package/src/components/select/styles/select.css +350 -0
- package/src/components/select/styles/select.min.css +1 -0
- package/src/components/select/styles/select.scss +330 -0
- package/src/components/text-input/styles/_index.scss +1 -0
- package/src/components/text-input/styles/text-input.css +513 -0
- package/src/components/text-input/styles/text-input.min.css +1 -0
- package/src/components/text-input/styles/text-input.scss +389 -0
- package/src/components/tooltip/styles/_index.scss +1 -0
- package/src/components/tooltip/styles/tooltip.css +136 -0
- package/src/components/tooltip/styles/tooltip.min.css +1 -0
- package/src/components/tooltip/styles/tooltip.scss +105 -0
|
@@ -0,0 +1,389 @@
|
|
|
1
|
+
@charset "UTF-8";
|
|
2
|
+
@use "sass:color";
|
|
3
|
+
@use "../../../core/jkl";
|
|
4
|
+
@use "../../../core/jkl/colors";
|
|
5
|
+
|
|
6
|
+
$_text-input-height: jkl.rem(48px);
|
|
7
|
+
$_text-input-height--mobile: jkl.rem(44px);
|
|
8
|
+
$_text-input-height--compact: jkl.rem(32px);
|
|
9
|
+
$_text-input-vertical-padding: jkl.$spacing-xs;
|
|
10
|
+
$_text-input-vertical-padding--compact: jkl.$spacing-2xs;
|
|
11
|
+
$_text-input-horizontal-padding: jkl.$spacing-s;
|
|
12
|
+
$_text-input-horizontal-padding--compact: jkl.$spacing-xs;
|
|
13
|
+
|
|
14
|
+
$_action-button-size: jkl.rem(48px);
|
|
15
|
+
$_action-button-size--mobile: jkl.rem(44px);
|
|
16
|
+
$_action-button-size--compact: jkl.rem(32px);
|
|
17
|
+
$_action-button-icon-size: jkl.rem(20px);
|
|
18
|
+
$_action-button-icon-size--compact: jkl.rem(18px);
|
|
19
|
+
$_action-button-padding: jkl.$spacing-xs 0;
|
|
20
|
+
$_action-button-padding--compact: 0;
|
|
21
|
+
$_action-button-focus-position: jkl.rem(8px);
|
|
22
|
+
$_action-button-focus-position--compact: 0;
|
|
23
|
+
|
|
24
|
+
$_text-input-focus-color: jkl.$color-granitt;
|
|
25
|
+
$_text-input-selection-color: color.scale(
|
|
26
|
+
$color: $_text-input-focus-color,
|
|
27
|
+
$alpha: -80%,
|
|
28
|
+
);
|
|
29
|
+
|
|
30
|
+
$_text-input-focus-color--inverted: jkl.$color-snohvit;
|
|
31
|
+
$_text-input-selection-color--inverted: color.scale(
|
|
32
|
+
$color: $_text-input-focus-color--inverted,
|
|
33
|
+
$alpha: -75%,
|
|
34
|
+
);
|
|
35
|
+
|
|
36
|
+
@include jkl.light-mode-variables {
|
|
37
|
+
--jkl-text-input-border-color: #{jkl.$color-stein};
|
|
38
|
+
--jkl-text-input-text-color: #{jkl.$color-granitt};
|
|
39
|
+
--jkl-text-input-placeholder-color: #{jkl.$color-stein};
|
|
40
|
+
--jkl-text-input-unit-color: #{jkl.$color-granitt};
|
|
41
|
+
--jkl-text-input-background-color: #{jkl.$color-hvit};
|
|
42
|
+
--jkl-text-input-focus-color: #{$_text-input-focus-color};
|
|
43
|
+
--jkl-text-input-error-background-color: #{jkl.$color-feil};
|
|
44
|
+
--jkl-text-input-error-text-color: #{jkl.$color-granitt};
|
|
45
|
+
--jkl-text-input-error-placeholder-color: #{jkl.$color-stein};
|
|
46
|
+
--jkl-text-input-selection-color: #{$_text-input-selection-color};
|
|
47
|
+
--jkl-text-input-error-selection-color: #{$_text-input-selection-color};
|
|
48
|
+
--jkl-text-area-counter-count-color: #{jkl.$color-stein};
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
@include jkl.dark-mode-variables {
|
|
52
|
+
--jkl-text-input-border-color: #{jkl.$color-svaberg};
|
|
53
|
+
--jkl-text-input-text-color: #{jkl.$color-snohvit};
|
|
54
|
+
--jkl-text-input-placeholder-color: #{jkl.$color-svaberg};
|
|
55
|
+
--jkl-text-input-unit-color: #{jkl.$color-snohvit};
|
|
56
|
+
--jkl-text-input-background-color: #{jkl.$color-skifer};
|
|
57
|
+
--jkl-text-input-focus-color: #{$_text-input-focus-color--inverted};
|
|
58
|
+
--jkl-text-input-selection-color: #{$_text-input-selection-color--inverted};
|
|
59
|
+
--jkl-text-input-error-background-color: #{jkl.$color-feil};
|
|
60
|
+
--jkl-text-input-error-text-color: #{jkl.$color-granitt};
|
|
61
|
+
--jkl-text-input-error-placeholder-color: #{jkl.$color-stein};
|
|
62
|
+
--jkl-text-input-error-selection-color: #{$_text-input-selection-color};
|
|
63
|
+
--jkl-text-area-counter-count-color: #{jkl.$color-svaberg};
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
@include jkl.comfortable-density-variables {
|
|
67
|
+
@include jkl.declare-font-variables("jkl-text-input", "body");
|
|
68
|
+
|
|
69
|
+
--jkl-text-input-height: #{$_text-input-height};
|
|
70
|
+
--jkl-text-input-vertical-padding: #{$_text-input-vertical-padding};
|
|
71
|
+
--jkl-text-input-horizontal-padding: #{$_text-input-horizontal-padding};
|
|
72
|
+
--jkl-text-input-padding: var(--jkl-text-input-vertical-padding) var(--jkl-text-input-horizontal-padding);
|
|
73
|
+
--jkl-text-input-action-button-size: #{$_action-button-size};
|
|
74
|
+
--jkl-text-input-action-button-icon-size: #{$_action-button-icon-size};
|
|
75
|
+
--jkl-text-input-action-button-padding: #{$_action-button-padding};
|
|
76
|
+
--jkl-text-input-action-button-focus-position: #{$_action-button-focus-position};
|
|
77
|
+
|
|
78
|
+
@include jkl.small-device {
|
|
79
|
+
--jkl-text-input-height: #{$_text-input-height--mobile};
|
|
80
|
+
--jkl-text-input-action-button-size: #{$_action-button-size--mobile};
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
@include jkl.compact-density-variables {
|
|
85
|
+
@include jkl.declare-font-variables("jkl-text-input", "small");
|
|
86
|
+
|
|
87
|
+
--jkl-text-input-height: #{$_text-input-height--compact};
|
|
88
|
+
--jkl-text-input-vertical-padding: #{$_text-input-vertical-padding--compact};
|
|
89
|
+
--jkl-text-input-horizontal-padding: #{$_text-input-horizontal-padding--compact};
|
|
90
|
+
--jkl-text-input-padding: var(--jkl-text-input-vertical-padding) var(--jkl-text-input-horizontal-padding);
|
|
91
|
+
--jkl-text-input-action-button-size: #{$_action-button-size--compact};
|
|
92
|
+
--jkl-text-input-action-button-icon-size: #{$_action-button-icon-size--compact};
|
|
93
|
+
--jkl-text-input-action-button-padding: #{$_action-button-padding--compact};
|
|
94
|
+
--jkl-text-input-action-button-focus-position: #{$_action-button-focus-position--compact};
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
@mixin _shared-input-styles {
|
|
98
|
+
background: none;
|
|
99
|
+
-webkit-appearance: none;
|
|
100
|
+
color: var(--jkl-color);
|
|
101
|
+
|
|
102
|
+
@include jkl.use-font-variables("jkl-text-input");
|
|
103
|
+
@include jkl.reset-outline;
|
|
104
|
+
@include jkl.remove-inner-outer-button;
|
|
105
|
+
|
|
106
|
+
// Placeholder text style
|
|
107
|
+
&::placeholder {
|
|
108
|
+
opacity: 1;
|
|
109
|
+
color: var(--jkl-text-input-placeholder-color);
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
// Color of text selection
|
|
113
|
+
&::selection {
|
|
114
|
+
background-color: var(--jkl-text-input-selection-color);
|
|
115
|
+
|
|
116
|
+
[data-theme="dark"] & {
|
|
117
|
+
background-color: var(--jkl-text-input-selection-color);
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
// Invalid state
|
|
122
|
+
&[aria-invalid="true"] {
|
|
123
|
+
color: var(--jkl-text-input-error-text-color);
|
|
124
|
+
|
|
125
|
+
&::placeholder {
|
|
126
|
+
color: var(--jkl-text-input-error-placeholder-color);
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
// Color of text selection
|
|
130
|
+
&::selection {
|
|
131
|
+
background-color: var(--jkl-text-input-error-selection-color);
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
& ~ .jkl-text-input-action-button {
|
|
135
|
+
color: var(--jkl-text-input-error-placeholder-color);
|
|
136
|
+
|
|
137
|
+
&:hover {
|
|
138
|
+
color: var(--jkl-text-input-error-text-color);
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
&:focus {
|
|
142
|
+
@include jkl.keyboard-navigation {
|
|
143
|
+
&::after {
|
|
144
|
+
box-shadow: inset 0 0 0 jkl.rem(2px) var(--jkl-text-input-error-text-color);
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
& ~ .jkl-text-input__unit {
|
|
151
|
+
color: var(--jkl-text-input-error-text-color);
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.jkl-text-input-action-button {
|
|
157
|
+
flex-shrink: 0;
|
|
158
|
+
display: flex;
|
|
159
|
+
box-sizing: border-box;
|
|
160
|
+
align-items: center;
|
|
161
|
+
justify-content: center;
|
|
162
|
+
background-color: transparent;
|
|
163
|
+
cursor: pointer;
|
|
164
|
+
padding: var(--jkl-text-input-action-button-padding);
|
|
165
|
+
height: var(--jkl-text-input-action-button-size);
|
|
166
|
+
width: var(--jkl-text-input-action-button-size);
|
|
167
|
+
color: var(--jkl-text-input-border-color);
|
|
168
|
+
|
|
169
|
+
// Unngå for langt mellomrom mellom ikon og teksten i feltet
|
|
170
|
+
margin-inline-start: calc(var(--jkl-text-input-horizontal-padding) * -1);
|
|
171
|
+
|
|
172
|
+
@include jkl.reset-outline;
|
|
173
|
+
|
|
174
|
+
.jkl-icon-button__icon {
|
|
175
|
+
height: var(--jkl-text-input-action-button-icon-size);
|
|
176
|
+
width: var(--jkl-text-input-action-button-icon-size);
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
&:hover {
|
|
180
|
+
color: var(--jkl-text-input-focus-color);
|
|
181
|
+
|
|
182
|
+
@include jkl.forced-colors-mode {
|
|
183
|
+
border: jkl.rem(2px) inset ButtonText;
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
&:focus {
|
|
188
|
+
@include jkl.keyboard-navigation {
|
|
189
|
+
position: relative;
|
|
190
|
+
|
|
191
|
+
&::after {
|
|
192
|
+
content: "";
|
|
193
|
+
position: absolute;
|
|
194
|
+
inset: var(--jkl-text-input-action-button-focus-position)
|
|
195
|
+
var(--jkl-text-input-action-button-focus-position)
|
|
196
|
+
var(--jkl-text-input-action-button-focus-position)
|
|
197
|
+
var(--jkl-text-input-action-button-focus-position);
|
|
198
|
+
box-shadow: inset 0 0 0 jkl.rem(2px) var(--jkl-text-input-focus-color);
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
@include jkl.forced-colors-mode {
|
|
204
|
+
border: revert;
|
|
205
|
+
background-color: revert;
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
@include jkl.forced-colors-svg-fallback($stroke: ButtonText);
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
.jkl-text-input-wrapper {
|
|
212
|
+
border-radius: jkl.rem(3px);
|
|
213
|
+
box-sizing: border-box;
|
|
214
|
+
max-width: 100%;
|
|
215
|
+
|
|
216
|
+
position: relative;
|
|
217
|
+
display: flex;
|
|
218
|
+
align-items: center;
|
|
219
|
+
height: var(--jkl-text-input-height);
|
|
220
|
+
|
|
221
|
+
@include jkl.use-font-variables("jkl-text-input");
|
|
222
|
+
@include jkl.motion;
|
|
223
|
+
transition-property: color, box-shadow, background-color;
|
|
224
|
+
|
|
225
|
+
color: var(--jkl-text-input-text-color);
|
|
226
|
+
box-shadow: inset 0 0 0 jkl.rem(1px) var(--jkl-text-input-border-color), 0 0 0 jkl.rem(1px) transparent;
|
|
227
|
+
background-color: transparent;
|
|
228
|
+
|
|
229
|
+
&:hover {
|
|
230
|
+
box-shadow: inset 0 0 0 jkl.rem(1px) var(--jkl-text-input-focus-color),
|
|
231
|
+
0 0 0 jkl.rem(1px) var(--jkl-text-input-focus-color);
|
|
232
|
+
border-color: var(--jkl-text-input-focus-color);
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
&:focus-within {
|
|
236
|
+
background-color: var(--jkl-text-input-background-color);
|
|
237
|
+
box-shadow: inset 0 0 0 jkl.rem(1px) var(--jkl-text-input-focus-color),
|
|
238
|
+
0 0 0 jkl.rem(1px) var(--jkl-text-input-focus-color);
|
|
239
|
+
border-color: var(--jkl-text-input-focus-color);
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
&[data-invalid="true"] {
|
|
243
|
+
background-color: var(--jkl-text-input-error-background-color);
|
|
244
|
+
color: var(--jkl-text-input-error-text-color);
|
|
245
|
+
}
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
.jkl-text-input {
|
|
249
|
+
display: flex;
|
|
250
|
+
flex-direction: column;
|
|
251
|
+
align-items: flex-start;
|
|
252
|
+
|
|
253
|
+
&__input {
|
|
254
|
+
padding: var(--jkl-text-input-padding);
|
|
255
|
+
width: 100%;
|
|
256
|
+
@include _shared-input-styles;
|
|
257
|
+
|
|
258
|
+
&--align-right {
|
|
259
|
+
text-align: right;
|
|
260
|
+
}
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
&__unit {
|
|
264
|
+
padding-inline-end: var(--jkl-text-input-horizontal-padding);
|
|
265
|
+
padding-block: var(--jkl-text-input-vertical-padding);
|
|
266
|
+
color: var(--jkl-text-input-unit-color);
|
|
267
|
+
}
|
|
268
|
+
|
|
269
|
+
&__action-button {
|
|
270
|
+
margin-inline-start: calc(var(--jkl-text-input-horizontal-padding) * -1);
|
|
271
|
+
}
|
|
272
|
+
|
|
273
|
+
&--inline {
|
|
274
|
+
display: inline-block;
|
|
275
|
+
vertical-align: middle;
|
|
276
|
+
margin: jkl.rem(-2px) jkl.rem(4px);
|
|
277
|
+
}
|
|
278
|
+
}
|
|
279
|
+
|
|
280
|
+
.jkl-text-area {
|
|
281
|
+
height: auto;
|
|
282
|
+
width: 100%;
|
|
283
|
+
|
|
284
|
+
&__text-area {
|
|
285
|
+
scrollbar-color: var(--jkl-color) transparent; // Unngå at scrollbar ligger oppå rammen
|
|
286
|
+
box-sizing: border-box;
|
|
287
|
+
resize: none; // Fjern mulighet for resizing av feltet
|
|
288
|
+
width: 100%;
|
|
289
|
+
padding: var(--jkl-text-input-padding);
|
|
290
|
+
max-height: var(--jkl-text-input-height);
|
|
291
|
+
height: var(--jkl-text-input-height);
|
|
292
|
+
min-height: var(--jkl-text-input-height);
|
|
293
|
+
|
|
294
|
+
@include jkl.motion;
|
|
295
|
+
transition-property: height, min-height, max-height, padding;
|
|
296
|
+
@include _shared-input-styles;
|
|
297
|
+
}
|
|
298
|
+
|
|
299
|
+
.jkl-text-input-wrapper {
|
|
300
|
+
height: auto;
|
|
301
|
+
max-height: 100%;
|
|
302
|
+
}
|
|
303
|
+
|
|
304
|
+
&--start-open {
|
|
305
|
+
.jkl-text-input-wrapper {
|
|
306
|
+
max-height: 100%;
|
|
307
|
+
}
|
|
308
|
+
}
|
|
309
|
+
|
|
310
|
+
&--auto-expand {
|
|
311
|
+
.jkl-text-area__text-area {
|
|
312
|
+
overflow: hidden; // Skjul scrollbar når høyden autojusteres
|
|
313
|
+
}
|
|
314
|
+
}
|
|
315
|
+
|
|
316
|
+
&:has(.jkl-text-area__counter) {
|
|
317
|
+
$progress-bar-height: jkl.rem(4px);
|
|
318
|
+
|
|
319
|
+
.jkl-text-input-wrapper {
|
|
320
|
+
position: relative;
|
|
321
|
+
|
|
322
|
+
&[data-has-content="true"],
|
|
323
|
+
&:focus-within {
|
|
324
|
+
padding-bottom: calc(var(--jkl-text-input-height) + #{$progress-bar-height});
|
|
325
|
+
}
|
|
326
|
+
}
|
|
327
|
+
|
|
328
|
+
.jkl-text-area__counter {
|
|
329
|
+
@include jkl.motion;
|
|
330
|
+
transition-property: opacity;
|
|
331
|
+
opacity: 0;
|
|
332
|
+
|
|
333
|
+
pointer-events: none; // La brukeren klikke gjennom telleren når feltet er kollapset
|
|
334
|
+
position: absolute;
|
|
335
|
+
bottom: 0;
|
|
336
|
+
left: 0;
|
|
337
|
+
right: 0;
|
|
338
|
+
|
|
339
|
+
&-count {
|
|
340
|
+
padding: var(--jkl-text-input-padding);
|
|
341
|
+
color: var(--jkl-text-area-counter-count-color);
|
|
342
|
+
@include jkl.text-style("small");
|
|
343
|
+
}
|
|
344
|
+
|
|
345
|
+
&-progress {
|
|
346
|
+
background-color: transparent;
|
|
347
|
+
height: $progress-bar-height;
|
|
348
|
+
width: 100%;
|
|
349
|
+
overflow: hidden;
|
|
350
|
+
|
|
351
|
+
&::after {
|
|
352
|
+
content: "";
|
|
353
|
+
width: var(--progress-width, 100%);
|
|
354
|
+
display: block;
|
|
355
|
+
height: $progress-bar-height;
|
|
356
|
+
background-color: var(--jkl-color);
|
|
357
|
+
transition-property: width;
|
|
358
|
+
@include jkl.motion("standard", "lazy");
|
|
359
|
+
}
|
|
360
|
+
}
|
|
361
|
+
}
|
|
362
|
+
|
|
363
|
+
&:focus-within .jkl-text-area__counter {
|
|
364
|
+
opacity: 1;
|
|
365
|
+
transition-delay: jkl.timing("productive"); // Vent med å fade inn til feltet er ekspandert
|
|
366
|
+
}
|
|
367
|
+
|
|
368
|
+
[aria-invalid="true"] ~ .jkl-text-area__counter {
|
|
369
|
+
color: var(--jkl-text-input-error-text-color);
|
|
370
|
+
}
|
|
371
|
+
}
|
|
372
|
+
}
|
|
373
|
+
|
|
374
|
+
// Nytteklasser for tekstfelt med $num antall rader
|
|
375
|
+
@for $num from 3 through 10 {
|
|
376
|
+
.jkl-text-area__text-area--#{$num}-rows:focus,
|
|
377
|
+
.jkl-text-area__text-area--#{$num}-rows:not(:placeholder-shown),
|
|
378
|
+
.jkl-text-area--start-open .jkl-text-area__text-area--#{$num}-rows {
|
|
379
|
+
--height: calc(var(--jkl-text-input-line-height) * #{$num});
|
|
380
|
+
--vertical-padding: calc(var(--jkl-text-input-vertical-padding) * 2);
|
|
381
|
+
|
|
382
|
+
// (#2751) Ekspanderende får inline style med height auto,
|
|
383
|
+
// som gir et "hopp" dersom det er en teller og vi
|
|
384
|
+
// ikke har en minimumshøyde.
|
|
385
|
+
min-height: calc(var(--height) + var(--vertical-padding)); // (#2751)
|
|
386
|
+
height: calc(var(--height) + var(--vertical-padding));
|
|
387
|
+
max-height: 100%;
|
|
388
|
+
}
|
|
389
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
@forward "tooltip";
|
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Do not edit directly
|
|
3
|
+
* Generated on Mon, 23 Sep 2024 08:51:40 GMT
|
|
4
|
+
*/
|
|
5
|
+
:root,
|
|
6
|
+
[data-layout-density=comfortable],
|
|
7
|
+
[data-density=comfortable] {
|
|
8
|
+
--jkl-tooltip-size: 1.5rem;
|
|
9
|
+
--jkl-tooltip-content-padding: 1rem;
|
|
10
|
+
}
|
|
11
|
+
@media (width >= 0) and (max-width: 679px) {
|
|
12
|
+
:root,
|
|
13
|
+
[data-layout-density=comfortable],
|
|
14
|
+
[data-density=comfortable] {
|
|
15
|
+
--jkl-tooltip-size: 1.25rem;
|
|
16
|
+
--jkl-tooltip-content-padding: 0.75rem;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
[data-layout-density=compact],
|
|
21
|
+
[data-density=compact] {
|
|
22
|
+
--jkl-tooltip-size: 1.25rem;
|
|
23
|
+
--jkl-tooltip-content-padding: 0.5rem;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.jkl-tooltip-trigger {
|
|
27
|
+
background-color: unset;
|
|
28
|
+
padding: unset;
|
|
29
|
+
color: unset;
|
|
30
|
+
outline: 0;
|
|
31
|
+
border-style: none;
|
|
32
|
+
outline-style: none;
|
|
33
|
+
}
|
|
34
|
+
.jkl-tooltip-trigger:active, .jkl-tooltip-trigger:hover, .jkl-tooltip-trigger:focus {
|
|
35
|
+
outline: 0;
|
|
36
|
+
outline-style: none;
|
|
37
|
+
}
|
|
38
|
+
@media screen and (forced-colors: active) {
|
|
39
|
+
.jkl-tooltip-trigger {
|
|
40
|
+
outline: revert;
|
|
41
|
+
border-style: revert;
|
|
42
|
+
outline-style: revert;
|
|
43
|
+
}
|
|
44
|
+
.jkl-tooltip-trigger:active, .jkl-tooltip-trigger:hover, .jkl-tooltip-trigger:focus {
|
|
45
|
+
outline: revert;
|
|
46
|
+
outline-style: revert;
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
html:not([data-mousenavigation]):not([data-touchnavigation]) .jkl-tooltip-trigger:focus {
|
|
50
|
+
--jkl-icon-weight: 500;
|
|
51
|
+
font-weight: 700;
|
|
52
|
+
letter-spacing: -0.014em;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.jkl-tooltip-content {
|
|
56
|
+
--background-color: var(--jkl-color-background-container-inverted);
|
|
57
|
+
--text-color: var(--jkl-color-text-inverted);
|
|
58
|
+
font-size: 1rem;
|
|
59
|
+
line-height: 1.5rem;
|
|
60
|
+
font-weight: 400;
|
|
61
|
+
--jkl-icon-weight: 300;
|
|
62
|
+
background-color: var(--background-color);
|
|
63
|
+
color: var(--text-color);
|
|
64
|
+
display: inline-block;
|
|
65
|
+
min-width: min-content;
|
|
66
|
+
max-width: min(19.375rem, 100%);
|
|
67
|
+
padding: var(--jkl-tooltip-content-padding);
|
|
68
|
+
position: absolute;
|
|
69
|
+
z-index: 10000;
|
|
70
|
+
}
|
|
71
|
+
.jkl-tooltip-content[data-placement^=top] > .jkl-tooltip-content__arrow {
|
|
72
|
+
bottom: -0.5rem;
|
|
73
|
+
}
|
|
74
|
+
.jkl-tooltip-content[data-placement^=bottom] > .jkl-tooltip-content__arrow {
|
|
75
|
+
top: -0.5rem;
|
|
76
|
+
}
|
|
77
|
+
.jkl-tooltip-content[data-placement^=left] > .jkl-tooltip-content__arrow {
|
|
78
|
+
right: -0.5rem;
|
|
79
|
+
}
|
|
80
|
+
.jkl-tooltip-content[data-placement^=right] > .jkl-tooltip-content__arrow {
|
|
81
|
+
left: -0.5rem;
|
|
82
|
+
}
|
|
83
|
+
@media screen and (forced-colors: active) {
|
|
84
|
+
.jkl-tooltip-content {
|
|
85
|
+
border: 1px solid CanvasText;
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
.jkl-tooltip-content__arrow {
|
|
89
|
+
overflow: hidden;
|
|
90
|
+
position: absolute;
|
|
91
|
+
background-color: var(--background-color);
|
|
92
|
+
transform: rotate(45deg);
|
|
93
|
+
height: 1rem;
|
|
94
|
+
width: 1rem;
|
|
95
|
+
}
|
|
96
|
+
@media screen and (forced-colors: active) {
|
|
97
|
+
.jkl-tooltip-content__arrow {
|
|
98
|
+
background-color: CanvasText;
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
.jkl-tooltip-question-button {
|
|
103
|
+
--button-color: var(--jkl-color-text-interactive);
|
|
104
|
+
transition-timing-function: ease-in;
|
|
105
|
+
transition-duration: 100ms;
|
|
106
|
+
transition-property: color;
|
|
107
|
+
cursor: pointer;
|
|
108
|
+
background-color: transparent;
|
|
109
|
+
padding: 0;
|
|
110
|
+
display: inline-flex;
|
|
111
|
+
align-items: center;
|
|
112
|
+
color: var(--button-color);
|
|
113
|
+
transform: translateY(max(0.16em, 0.25rem));
|
|
114
|
+
font-size: 1.2em;
|
|
115
|
+
outline: 0;
|
|
116
|
+
border-style: none;
|
|
117
|
+
outline-style: none;
|
|
118
|
+
}
|
|
119
|
+
.jkl-tooltip-question-button:active, .jkl-tooltip-question-button:hover, .jkl-tooltip-question-button:focus {
|
|
120
|
+
outline: 0;
|
|
121
|
+
outline-style: none;
|
|
122
|
+
}
|
|
123
|
+
@media screen and (forced-colors: active) {
|
|
124
|
+
.jkl-tooltip-question-button {
|
|
125
|
+
outline: revert;
|
|
126
|
+
border-style: revert;
|
|
127
|
+
outline-style: revert;
|
|
128
|
+
}
|
|
129
|
+
.jkl-tooltip-question-button:active, .jkl-tooltip-question-button:hover, .jkl-tooltip-question-button:focus {
|
|
130
|
+
outline: revert;
|
|
131
|
+
outline-style: revert;
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
.jkl-tooltip-question-button:hover {
|
|
135
|
+
--button-color: var(--jkl-color-text-interactive-hover);
|
|
136
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
:root,[data-density=comfortable],[data-layout-density=comfortable]{--jkl-tooltip-size:1.5rem;--jkl-tooltip-content-padding:1rem}@media (width >= 0) and (max-width:679px){:root,[data-density=comfortable],[data-layout-density=comfortable]{--jkl-tooltip-size:1.25rem;--jkl-tooltip-content-padding:0.75rem}}[data-density=compact],[data-layout-density=compact]{--jkl-tooltip-size:1.25rem;--jkl-tooltip-content-padding:0.5rem}.jkl-tooltip-trigger{background-color:unset;border-style:none;color:unset;padding:unset}.jkl-tooltip-trigger,.jkl-tooltip-trigger:active,.jkl-tooltip-trigger:focus,.jkl-tooltip-trigger:hover{outline:0;outline-style:none}@media screen and (forced-colors:active){.jkl-tooltip-trigger{border-style:revert}.jkl-tooltip-trigger,.jkl-tooltip-trigger:active,.jkl-tooltip-trigger:focus,.jkl-tooltip-trigger:hover{outline:revert;outline-style:revert}}html:not([data-mousenavigation]):not([data-touchnavigation]) .jkl-tooltip-trigger:focus{--jkl-icon-weight:500;font-weight:700;letter-spacing:-.014em}.jkl-tooltip-content{--background-color:var(--jkl-color-background-container-inverted);--text-color:var(--jkl-color-text-inverted);--jkl-icon-weight:300;background-color:var(--background-color);color:var(--text-color);display:inline-block;font-size:1rem;font-weight:400;line-height:1.5rem;max-width:min(19.375rem,100%);min-width:-webkit-min-content;min-width:min-content;padding:var(--jkl-tooltip-content-padding);position:absolute;z-index:10000}.jkl-tooltip-content[data-placement^=top]>.jkl-tooltip-content__arrow{bottom:-.5rem}.jkl-tooltip-content[data-placement^=bottom]>.jkl-tooltip-content__arrow{top:-.5rem}.jkl-tooltip-content[data-placement^=left]>.jkl-tooltip-content__arrow{right:-.5rem}.jkl-tooltip-content[data-placement^=right]>.jkl-tooltip-content__arrow{left:-.5rem}@media screen and (forced-colors:active){.jkl-tooltip-content{border:1px solid CanvasText}}.jkl-tooltip-content__arrow{background-color:var(--background-color);height:1rem;overflow:hidden;position:absolute;transform:rotate(45deg);width:1rem}@media screen and (forced-colors:active){.jkl-tooltip-content__arrow{background-color:CanvasText}}.jkl-tooltip-question-button{--button-color:var(--jkl-color-text-interactive);align-items:center;background-color:initial;border-style:none;color:var(--button-color);cursor:pointer;display:inline-flex;font-size:1.2em;outline:0;outline-style:none;padding:0;transform:translateY(max(.16em,.25rem));transition-duration:.1s;transition-property:color;transition-timing-function:ease-in}.jkl-tooltip-question-button:active,.jkl-tooltip-question-button:focus,.jkl-tooltip-question-button:hover{outline:0;outline-style:none}@media screen and (forced-colors:active){.jkl-tooltip-question-button{border-style:revert}.jkl-tooltip-question-button,.jkl-tooltip-question-button:active,.jkl-tooltip-question-button:focus,.jkl-tooltip-question-button:hover{outline:revert;outline-style:revert}}.jkl-tooltip-question-button:hover{--button-color:var(--jkl-color-text-interactive-hover)}
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
@charset "UTF-8";
|
|
2
|
+
@use "../../../core/jkl";
|
|
3
|
+
|
|
4
|
+
$_tooltip-border-width: jkl.rem(1px);
|
|
5
|
+
$_tooltip-arrow-height: jkl.rem(8px);
|
|
6
|
+
$_focus-ring-distance: jkl.rem(-1px); // Negativ margin for å unngå subpixel mellomrom mellom border og box-shadow
|
|
7
|
+
$_focus-ring-width: jkl.rem(2px);
|
|
8
|
+
|
|
9
|
+
@include jkl.comfortable-density-variables {
|
|
10
|
+
--jkl-tooltip-size: #{jkl.rem(24px)};
|
|
11
|
+
--jkl-tooltip-content-padding: #{jkl.$spacing-m};
|
|
12
|
+
|
|
13
|
+
@include jkl.small-device {
|
|
14
|
+
--jkl-tooltip-size: #{jkl.rem(20px)};
|
|
15
|
+
--jkl-tooltip-content-padding: #{jkl.$spacing-s};
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
@include jkl.compact-density-variables {
|
|
20
|
+
--jkl-tooltip-size: #{jkl.rem(20px)};
|
|
21
|
+
--jkl-tooltip-content-padding: #{jkl.$spacing-xs};
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.jkl-tooltip-trigger {
|
|
25
|
+
background-color: unset;
|
|
26
|
+
padding: unset;
|
|
27
|
+
color: unset;
|
|
28
|
+
|
|
29
|
+
@include jkl.reset-outline;
|
|
30
|
+
|
|
31
|
+
&:focus {
|
|
32
|
+
@include jkl.keyboard-navigation {
|
|
33
|
+
@include jkl.no-grow-bold;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.jkl-tooltip-content {
|
|
39
|
+
--background-color: var(--jkl-color-background-container-inverted);
|
|
40
|
+
--text-color: var(--jkl-color-text-inverted);
|
|
41
|
+
|
|
42
|
+
@include jkl.text-style("small");
|
|
43
|
+
background-color: var(--background-color);
|
|
44
|
+
color: var(--text-color);
|
|
45
|
+
display: inline-block;
|
|
46
|
+
min-width: min-content;
|
|
47
|
+
max-width: min(jkl.rem(310px), 100%); // 10px mindre enn smaleste støttede skjerm
|
|
48
|
+
padding: var(--jkl-tooltip-content-padding);
|
|
49
|
+
position: absolute;
|
|
50
|
+
z-index: jkl.$z-index--floating;
|
|
51
|
+
|
|
52
|
+
&[data-placement^="top"] > .jkl-tooltip-content__arrow {
|
|
53
|
+
bottom: -#{$_tooltip-arrow-height};
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
&[data-placement^="bottom"] > .jkl-tooltip-content__arrow {
|
|
57
|
+
top: -#{$_tooltip-arrow-height};
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
&[data-placement^="left"] > .jkl-tooltip-content__arrow {
|
|
61
|
+
right: -#{$_tooltip-arrow-height};
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
&[data-placement^="right"] > .jkl-tooltip-content__arrow {
|
|
65
|
+
left: -#{$_tooltip-arrow-height};
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
@include jkl.forced-colors-mode {
|
|
69
|
+
border: 1px solid CanvasText;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
&__arrow {
|
|
73
|
+
overflow: hidden;
|
|
74
|
+
position: absolute;
|
|
75
|
+
background-color: var(--background-color);
|
|
76
|
+
transform: rotate(45deg);
|
|
77
|
+
height: $_tooltip-arrow-height * 2;
|
|
78
|
+
width: $_tooltip-arrow-height * 2;
|
|
79
|
+
|
|
80
|
+
@include jkl.forced-colors-mode {
|
|
81
|
+
background-color: CanvasText;
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
.jkl-tooltip-question-button {
|
|
87
|
+
--button-color: var(--jkl-color-text-interactive);
|
|
88
|
+
|
|
89
|
+
@include jkl.motion("exit", "snappy");
|
|
90
|
+
transition-property: color;
|
|
91
|
+
cursor: pointer;
|
|
92
|
+
background-color: transparent;
|
|
93
|
+
padding: 0;
|
|
94
|
+
display: inline-flex;
|
|
95
|
+
align-items: center;
|
|
96
|
+
color: var(--button-color);
|
|
97
|
+
transform: translateY(max(0.16em, jkl.rem(4px))); // Cap på 4px
|
|
98
|
+
font-size: 1.2em;
|
|
99
|
+
|
|
100
|
+
@include jkl.reset-outline;
|
|
101
|
+
|
|
102
|
+
&:hover {
|
|
103
|
+
--button-color: var(--jkl-color-text-interactive-hover);
|
|
104
|
+
}
|
|
105
|
+
}
|