@helsenorge/designsystem-react 1.0.0-beta106 → 1.0.0-beta107
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/Button-7e82091f.js +2 -0
- package/Button-7e82091f.js.map +1 -0
- package/CHANGELOG.md +52 -52
- package/Checkbox-f2418dc5.js +2 -0
- package/Checkbox-f2418dc5.js.map +1 -0
- package/Close-d81081c8.js +2 -0
- package/Close-d81081c8.js.map +1 -0
- package/{FormGroup-b2b6efe0.js → FormGroup-af33981a.js} +2 -2
- package/FormGroup-af33981a.js.map +1 -0
- package/Input-31d7accc.js +2 -0
- package/Input-31d7accc.js.map +1 -0
- package/Modal-ff546be0.js +2 -0
- package/Modal-ff546be0.js.map +1 -0
- package/README.md +69 -69
- package/Validation-4041c083.js +2 -0
- package/Validation-4041c083.js.map +1 -0
- package/components/AnchorLink/AnchorLink.d.ts +18 -18
- package/components/AnchorLink/index.d.ts +3 -3
- package/components/AnchorLink/index.js +1 -1
- package/components/AnchorLink/styles.module.scss +63 -63
- package/components/AnchorLink/styles.module.scss.d.ts +10 -10
- package/components/Avatar/Avatar.d.ts +15 -15
- package/components/Avatar/index.d.ts +3 -3
- package/components/Avatar/index.js +1 -1
- package/components/Avatar/styles.module.scss +22 -22
- package/components/Avatar/styles.module.scss.d.ts +11 -11
- package/components/Badge/Badge.d.ts +16 -16
- package/components/Badge/index.d.ts +3 -3
- package/components/Badge/styles.module.scss +41 -41
- package/components/Badge/styles.module.scss.d.ts +17 -17
- package/components/Button/Button.d.ts +41 -41
- package/components/Button/index.d.ts +3 -3
- package/components/Button/index.js +1 -1
- package/components/Button/styles.module.scss +434 -434
- package/components/Button/styles.module.scss.d.ts +34 -34
- package/components/ButtonWithModal/ButtonWithModal.d.ts +10 -10
- package/components/ButtonWithModal/index.d.ts +3 -3
- package/components/ButtonWithModal/index.js +1 -1
- package/components/Checkbox/Checkbox.d.ts +30 -30
- package/components/Checkbox/index.d.ts +3 -3
- package/components/Checkbox/index.js +1 -1
- package/components/Checkbox/styles.module.scss +204 -204
- package/components/Checkbox/styles.module.scss.d.ts +26 -26
- package/components/Close/Close.d.ts +11 -11
- package/components/Close/index.d.ts +3 -3
- package/components/Close/index.js +1 -1
- package/components/Close/styles.module.scss +32 -32
- package/components/Close/styles.module.scss.d.ts +9 -9
- package/components/Expander/Expander.d.ts +32 -32
- package/components/Expander/Expander.d.ts.map +1 -1
- package/components/Expander/index.d.ts +3 -3
- package/components/Expander/index.js +1 -1
- package/components/Expander/styles.module.scss +165 -165
- package/components/Expander/styles.module.scss.d.ts +42 -42
- package/components/ExpanderList/ExpanderList.d.ts +47 -45
- package/components/ExpanderList/ExpanderList.d.ts.map +1 -1
- package/components/ExpanderList/index.d.ts +3 -3
- package/components/ExpanderList/index.js +1 -1
- package/components/ExpanderList/styles.module.scss +160 -160
- package/components/ExpanderList/styles.module.scss.d.ts +28 -28
- package/components/FormExample/FormExample.d.ts +15 -15
- package/components/FormExample/index.d.ts +3 -3
- package/components/FormExample/index.js +1 -1
- package/components/FormExample/index.js.map +1 -1
- package/components/FormGroup/FormGroup.d.ts +24 -24
- package/components/FormGroup/index.d.ts +3 -3
- package/components/FormGroup/index.js +1 -1
- package/components/FormGroup/styles.module.scss +67 -67
- package/components/FormGroup/styles.module.scss.d.ts +16 -16
- package/components/HighlightBox/HighlightBox.d.ts +26 -26
- package/components/HighlightBox/index.d.ts +3 -3
- package/components/HighlightBox/index.js +1 -1
- package/components/HighlightBox/styles.module.scss +174 -174
- package/components/Icons/ActiveMonitoring.d.ts +4 -4
- package/components/Icons/AcupunctureBack.d.ts +4 -4
- package/components/Icons/AcupunctureBack.js +1 -1
- package/components/Icons/AdditionalIconInformation.js +263 -263
- package/components/Icons/AdditionalIconInformation.js.map +1 -1
- package/components/Icons/AlarmClock.d.ts +4 -4
- package/components/Icons/AlertSignFill.d.ts +4 -4
- package/components/Icons/AlertSignStroke.d.ts +4 -4
- package/components/Icons/Amputation.d.ts +4 -4
- package/components/Icons/Anxiety.d.ts +4 -4
- package/components/Icons/Apple.d.ts +4 -4
- package/components/Icons/Archive.d.ts +4 -4
- package/components/Icons/ArmFlexing.d.ts +4 -4
- package/components/Icons/ArrowLeft.d.ts +4 -4
- package/components/Icons/ArrowRight.d.ts +4 -4
- package/components/Icons/ArrowUpRight.d.ts +4 -4
- package/components/Icons/Attachment.d.ts +4 -4
- package/components/Icons/Atv.d.ts +4 -4
- package/components/Icons/Avatar.d.ts +4 -4
- package/components/Icons/AwakePersonOnPillow.d.ts +4 -4
- package/components/Icons/Baby.d.ts +4 -4
- package/components/Icons/BandAid.d.ts +4 -4
- package/components/Icons/BeerAndPills.d.ts +4 -4
- package/components/Icons/Bell.d.ts +4 -4
- package/components/Icons/Bike.d.ts +4 -4
- package/components/Icons/BirthControl.d.ts +4 -4
- package/components/Icons/BirthdayCake.d.ts +4 -4
- package/components/Icons/Boat.d.ts +4 -4
- package/components/Icons/Body.d.ts +4 -4
- package/components/Icons/Brain.d.ts +4 -4
- package/components/Icons/BreastReconstruction.d.ts +4 -4
- package/components/Icons/BreastRemoval.d.ts +4 -4
- package/components/Icons/Breasts.d.ts +4 -4
- package/components/Icons/BrokenHeart.d.ts +4 -4
- package/components/Icons/BrokenPuzzle.d.ts +4 -4
- package/components/Icons/Bus.d.ts +4 -4
- package/components/Icons/Calendar.d.ts +4 -4
- package/components/Icons/CalendarChange.d.ts +4 -4
- package/components/Icons/CalendarCheck.d.ts +4 -4
- package/components/Icons/CalendarEvent.d.ts +4 -4
- package/components/Icons/CalendarSave.d.ts +4 -4
- package/components/Icons/Cancer.d.ts +4 -4
- package/components/Icons/Car.d.ts +4 -4
- package/components/Icons/Change.d.ts +4 -4
- package/components/Icons/Check.d.ts +4 -4
- package/components/Icons/CheckOutline.d.ts +4 -4
- package/components/Icons/Chest.d.ts +4 -4
- package/components/Icons/ChevronDown.d.ts +4 -4
- package/components/Icons/ChevronLeft.d.ts +4 -4
- package/components/Icons/ChevronRight.d.ts +4 -4
- package/components/Icons/ChevronUp.d.ts +4 -4
- package/components/Icons/ChevronsDown.d.ts +4 -4
- package/components/Icons/ChevronsUp.d.ts +4 -4
- package/components/Icons/ChildPlaying.d.ts +4 -4
- package/components/Icons/Cigarette.d.ts +4 -4
- package/components/Icons/Contacts.d.ts +4 -4
- package/components/Icons/Copy.d.ts +4 -4
- package/components/Icons/CoronaCertificate.d.ts +4 -4
- package/components/Icons/Coronavirus.d.ts +4 -4
- package/components/Icons/Cough.d.ts +4 -4
- package/components/Icons/CriticalHealthInfo.d.ts +4 -4
- package/components/Icons/Cross.d.ts +4 -4
- package/components/Icons/DataExchange.d.ts +4 -4
- package/components/Icons/DataReceived.d.ts +4 -4
- package/components/Icons/DataSent.d.ts +4 -4
- package/components/Icons/Depression.d.ts +4 -4
- package/components/Icons/DigestiveSystem.d.ts +4 -4
- package/components/Icons/Dizzy.d.ts +4 -4
- package/components/Icons/Documents.d.ts +4 -4
- package/components/Icons/Dog.d.ts +4 -4
- package/components/Icons/DonorCard.d.ts +4 -4
- package/components/Icons/Download.d.ts +4 -4
- package/components/Icons/Draft.d.ts +4 -4
- package/components/Icons/EChat.d.ts +4 -4
- package/components/Icons/EarNoseThroat.d.ts +4 -4
- package/components/Icons/ElderlyPerson.d.ts +4 -4
- package/components/Icons/Embolization.d.ts +4 -4
- package/components/Icons/EnterFullScreen.d.ts +4 -4
- package/components/Icons/Envelope.d.ts +4 -4
- package/components/Icons/Epilepsy.d.ts +4 -4
- package/components/Icons/Eraser.d.ts +4 -4
- package/components/Icons/ErrorSignFill.d.ts +4 -4
- package/components/Icons/ErrorSignStroke.d.ts +4 -4
- package/components/Icons/EuropeanHealthCard.d.ts +4 -4
- package/components/Icons/ExitFullScreen.d.ts +4 -4
- package/components/Icons/Eye.d.ts +4 -4
- package/components/Icons/Facebook.d.ts +4 -4
- package/components/Icons/Female.d.ts +4 -4
- package/components/Icons/FemaleDoctor.d.ts +4 -4
- package/components/Icons/Ferry.d.ts +4 -4
- package/components/Icons/FingerBleed.d.ts +4 -4
- package/components/Icons/FirstAidKit.d.ts +4 -4
- package/components/Icons/FloppyDisk.d.ts +4 -4
- package/components/Icons/Football.d.ts +4 -4
- package/components/Icons/Form.d.ts +4 -4
- package/components/Icons/Forward.d.ts +4 -4
- package/components/Icons/Gallery.d.ts +4 -4
- package/components/Icons/Garden.d.ts +4 -4
- package/components/Icons/GasCan.d.ts +4 -4
- package/components/Icons/GenderIdentity.d.ts +4 -4
- package/components/Icons/Globe.d.ts +4 -4
- package/components/Icons/HandWaving.d.ts +4 -4
- package/components/Icons/HandWithDisease.d.ts +4 -4
- package/components/Icons/HealthClinic.d.ts +4 -4
- package/components/Icons/HealthWarning.d.ts +4 -4
- package/components/Icons/Heart.d.ts +4 -4
- package/components/Icons/HelpSign.d.ts +4 -4
- package/components/Icons/HelpingHand.d.ts +4 -4
- package/components/Icons/Hemodialysis.d.ts +4 -4
- package/components/Icons/Hiker.d.ts +4 -4
- package/components/Icons/Hipprosthesis.d.ts +4 -4
- package/components/Icons/History.d.ts +4 -4
- package/components/Icons/HivAndAids.d.ts +4 -4
- package/components/Icons/Home.d.ts +4 -4
- package/components/Icons/Hormone.d.ts +4 -4
- package/components/Icons/Hospital.d.ts +4 -4
- package/components/Icons/Hourglass.d.ts +4 -4
- package/components/Icons/Icon.d.ts +22 -22
- package/components/Icons/ImgFile.d.ts +4 -4
- package/components/Icons/Inbox.d.ts +4 -4
- package/components/Icons/InfoSignFill.d.ts +4 -4
- package/components/Icons/InfoSignStroke.d.ts +4 -4
- package/components/Icons/Instagram.d.ts +4 -4
- package/components/Icons/Intravenous.d.ts +4 -4
- package/components/Icons/JointPain.d.ts +4 -4
- package/components/Icons/Journal.d.ts +4 -4
- package/components/Icons/JpgFile.d.ts +4 -4
- package/components/Icons/Kidney.d.ts +4 -4
- package/components/Icons/KitchenScale.d.ts +4 -4
- package/components/Icons/Kjernejournal.d.ts +4 -4
- package/components/Icons/Laboratory.d.ts +4 -4
- package/components/Icons/LaptopBlog.d.ts +4 -4
- package/components/Icons/LawBook.d.ts +4 -4
- package/components/Icons/LightBulb.d.ts +4 -4
- package/components/Icons/List.d.ts +4 -4
- package/components/Icons/Location.d.ts +4 -4
- package/components/Icons/Lock.d.ts +4 -4
- package/components/Icons/Lungs.d.ts +4 -4
- package/components/Icons/Makeup.d.ts +4 -4
- package/components/Icons/MaleDoctor.d.ts +4 -4
- package/components/Icons/MaleDoctorAndPerson.d.ts +4 -4
- package/components/Icons/MaleGenitalia.d.ts +4 -4
- package/components/Icons/Medicine.d.ts +4 -4
- package/components/Icons/MedicineWarning.d.ts +4 -4
- package/components/Icons/MentalHealthAdult.d.ts +4 -4
- package/components/Icons/MentalHealthChild.d.ts +4 -4
- package/components/Icons/Menu.d.ts +4 -4
- package/components/Icons/Microscope.d.ts +4 -4
- package/components/Icons/Minus.d.ts +4 -4
- package/components/Icons/Mirror.d.ts +4 -4
- package/components/Icons/MobilePhone.d.ts +4 -4
- package/components/Icons/MotherHoldingBaby.d.ts +4 -4
- package/components/Icons/MuscleBack.d.ts +4 -4
- package/components/Icons/MuscleLeg.d.ts +4 -4
- package/components/Icons/Mushroom.d.ts +4 -4
- package/components/Icons/Music.d.ts +4 -4
- package/components/Icons/MusselsAndSalt.d.ts +4 -4
- package/components/Icons/NoEye.d.ts +4 -4
- package/components/Icons/NoEye.js +1 -1
- package/components/Icons/NoFilter.d.ts +4 -4
- package/components/Icons/Notepad.d.ts +4 -4
- package/components/Icons/Osteotomy.d.ts +4 -4
- package/components/Icons/PaintRoller.d.ts +4 -4
- package/components/Icons/PaperPlane.d.ts +4 -4
- package/components/Icons/PatientAndPerson.d.ts +4 -4
- package/components/Icons/Pause.d.ts +4 -4
- package/components/Icons/PdfFile.d.ts +4 -4
- package/components/Icons/Pencil.d.ts +4 -4
- package/components/Icons/PeopleTalking.d.ts +4 -4
- package/components/Icons/Peritonealdialysis.d.ts +4 -4
- package/components/Icons/Person.d.ts +4 -4
- package/components/Icons/PersonAndPatient.d.ts +4 -4
- package/components/Icons/PersonInXRayMachine.d.ts +4 -4
- package/components/Icons/PersonOverweight.d.ts +4 -4
- package/components/Icons/PersonRelaxing.d.ts +4 -4
- package/components/Icons/PersonWithBrain.d.ts +4 -4
- package/components/Icons/PersonWithBrokenArm.d.ts +4 -4
- package/components/Icons/PersonWithCrutches.d.ts +4 -4
- package/components/Icons/PersonWithJaw.d.ts +4 -4
- package/components/Icons/PersonWithMagnifyingGlass.d.ts +4 -4
- package/components/Icons/PersonWithSenses.d.ts +4 -4
- package/components/Icons/PersonWorking.d.ts +4 -4
- package/components/Icons/PizzaSlice.d.ts +4 -4
- package/components/Icons/Plane.d.ts +4 -4
- package/components/Icons/Plant.d.ts +4 -4
- package/components/Icons/Play.d.ts +4 -4
- package/components/Icons/PlusLarge.d.ts +4 -4
- package/components/Icons/PlusSmall.d.ts +4 -4
- package/components/Icons/PngFile.d.ts +4 -4
- package/components/Icons/Podcast.d.ts +4 -4
- package/components/Icons/PoisonInformation.d.ts +4 -4
- package/components/Icons/Pregnant.d.ts +4 -4
- package/components/Icons/Printer.d.ts +4 -4
- package/components/Icons/Psychosis.d.ts +4 -4
- package/components/Icons/Publication.d.ts +4 -4
- package/components/Icons/Puzzle.d.ts +4 -4
- package/components/Icons/QrCode.d.ts +4 -4
- package/components/Icons/Quarrel.d.ts +4 -4
- package/components/Icons/RadioTherapy.d.ts +4 -4
- package/components/Icons/RadioactiveTreatment.d.ts +4 -4
- package/components/Icons/Radioiodine.d.ts +4 -4
- package/components/Icons/Receipt.d.ts +4 -4
- package/components/Icons/Receptionist.d.ts +4 -4
- package/components/Icons/Recovery.d.ts +4 -4
- package/components/Icons/Referral.d.ts +4 -4
- package/components/Icons/Refresh.d.ts +4 -4
- package/components/Icons/Refund.d.ts +4 -4
- package/components/Icons/Reply.d.ts +4 -4
- package/components/Icons/Rocket.d.ts +4 -4
- package/components/Icons/RtfFile.d.ts +4 -4
- package/components/Icons/STDs.d.ts +4 -4
- package/components/Icons/Save.d.ts +4 -4
- package/components/Icons/Scale.d.ts +4 -4
- package/components/Icons/Search.d.ts +4 -4
- package/components/Icons/SectionSign.d.ts +4 -4
- package/components/Icons/SectionSign.js +1 -1
- package/components/Icons/Settings.d.ts +4 -4
- package/components/Icons/Sexualorientation.d.ts +4 -4
- package/components/Icons/ShakingHand.d.ts +4 -4
- package/components/Icons/Share.d.ts +4 -4
- package/components/Icons/Shield.d.ts +4 -4
- package/components/Icons/ShuntOperation.d.ts +4 -4
- package/components/Icons/Skeleton.d.ts +4 -4
- package/components/Icons/Skin.d.ts +4 -4
- package/components/Icons/Snake.d.ts +4 -4
- package/components/Icons/Snapchat.d.ts +4 -4
- package/components/Icons/SpeechBubble.d.ts +4 -4
- package/components/Icons/SpeechBubble.js +1 -1
- package/components/Icons/Spray.d.ts +4 -4
- package/components/Icons/Stopwatch.d.ts +4 -4
- package/components/Icons/SupportingPerson.d.ts +4 -4
- package/components/Icons/SupportingPerson.js +1 -1
- package/components/Icons/Surgery.d.ts +4 -4
- package/components/Icons/Syringe.d.ts +4 -4
- package/components/Icons/Syringe.js +1 -1
- package/components/Icons/Taxi.d.ts +4 -4
- package/components/Icons/TeddyBear.d.ts +4 -4
- package/components/Icons/Teenagers.d.ts +4 -4
- package/components/Icons/ThinkingAboutBaby.d.ts +4 -4
- package/components/Icons/Ticket.d.ts +4 -4
- package/components/Icons/TimePassing.d.ts +4 -4
- package/components/Icons/Toolbox.d.ts +4 -4
- package/components/Icons/Tooth.d.ts +4 -4
- package/components/Icons/TotalKneeProsthesis.d.ts +4 -4
- package/components/Icons/Train.d.ts +4 -4
- package/components/Icons/Transplantation.d.ts +4 -4
- package/components/Icons/TrashCan.d.ts +4 -4
- package/components/Icons/Twitter.d.ts +4 -4
- package/components/Icons/Undo.d.ts +4 -4
- package/components/Icons/UniProsthesis.d.ts +4 -4
- package/components/Icons/Upload.d.ts +4 -4
- package/components/Icons/UserOrganization.d.ts +4 -4
- package/components/Icons/Vaccine.d.ts +4 -4
- package/components/Icons/VerticalDots.d.ts +4 -4
- package/components/Icons/VideoCamera.d.ts +4 -4
- package/components/Icons/VideoChat.d.ts +4 -4
- package/components/Icons/Wallet.d.ts +4 -4
- package/components/Icons/Watch.d.ts +4 -4
- package/components/Icons/Website.d.ts +4 -4
- package/components/Icons/Wheelchair.d.ts +4 -4
- package/components/Icons/WheelchairActive.d.ts +4 -4
- package/components/Icons/Window.d.ts +4 -4
- package/components/Icons/WordDocument.d.ts +4 -4
- package/components/Icons/WorkSuitcase.d.ts +4 -4
- package/components/Icons/X.d.ts +4 -4
- package/components/Icons/XOutline.d.ts +4 -4
- package/components/Icons/XmlFile.d.ts +4 -4
- package/components/Icons/YouTube.d.ts +4 -4
- package/components/Icons/Zoom.d.ts +4 -4
- package/components/Icons/index.d.ts +4 -4
- package/components/Icons/index.js +1 -1
- package/components/Input/Input.d.ts +54 -54
- package/components/Input/index.d.ts +3 -3
- package/components/Input/index.js +1 -1
- package/components/Input/styles.module.scss +59 -59
- package/components/Input/styles.module.scss.d.ts +23 -23
- package/components/LinkList/LinkList.d.ts +41 -41
- package/components/LinkList/index.d.ts +3 -3
- package/components/LinkList/index.js +1 -1
- package/components/LinkList/styles.module.scss +147 -147
- package/components/LinkList/styles.module.scss.d.ts +26 -26
- package/components/List/List.d.ts +9 -9
- package/components/List/index.d.ts +3 -3
- package/components/List/styles.module.scss +11 -11
- package/components/List/styles.module.scss.d.ts +10 -10
- package/components/Loader/Loader.d.ts +32 -32
- package/components/Loader/index.d.ts +3 -3
- package/components/Loader/styles.module.scss +194 -194
- package/components/Logo/Logo.d.ts +17 -17
- package/components/Logo/index.d.ts +3 -3
- package/components/Modal/Modal.d.ts +69 -69
- package/components/Modal/__mocks__/IntersectionObserver.d.ts +5 -5
- package/components/Modal/index.d.ts +3 -3
- package/components/Modal/index.js +1 -1
- package/components/Modal/styles.module.scss +243 -243
- package/components/Modal/styles.module.scss.d.ts +41 -41
- package/components/NotificationPanel/NotificationPanel.d.ts +47 -47
- package/components/NotificationPanel/index.d.ts +3 -3
- package/components/NotificationPanel/index.js +1 -1
- package/components/NotificationPanel/styles.module.scss +153 -153
- package/components/NotificationPanel/styles.module.scss.d.ts +33 -33
- package/components/Portal/index.d.ts +12 -12
- package/components/RadioButton/RadioButton.d.ts +30 -30
- package/components/RadioButton/index.d.ts +3 -3
- package/components/RadioButton/styles.module.scss +236 -236
- package/components/RadioButton/styles.module.scss.d.ts +23 -23
- package/components/Slider/Slider.d.ts +19 -19
- package/components/Slider/SliderUtils.d.ts +40 -40
- package/components/Slider/index.d.ts +3 -3
- package/components/Slider/styles.module.scss +85 -85
- package/components/Slider/styles.module.scss.d.ts +19 -19
- package/components/Spacer/Spacer.d.ts +12 -12
- package/components/Spacer/index.d.ts +3 -3
- package/components/Spacer/styles.module.scss +47 -47
- package/components/Spacer/styles.module.scss.d.ts +22 -22
- package/components/Textarea/Textarea.d.ts +36 -36
- package/components/Textarea/index.d.ts +3 -3
- package/components/Textarea/styles.module.scss +57 -57
- package/components/Textarea/styles.module.scss.d.ts +26 -26
- package/components/Tile/Tile.d.ts +33 -33
- package/components/Tile/index.d.ts +3 -3
- package/components/Tile/index.js +1 -1
- package/components/Tile/styles.module.scss +115 -115
- package/components/Tile/styles.module.scss.d.ts +18 -18
- package/components/Title/Title.d.ts +25 -25
- package/components/Title/index.d.ts +3 -3
- package/components/Title/styles.module.scss +27 -27
- package/components/Title/styles.module.scss.d.ts +15 -15
- package/components/Validation/Validation.d.ts +16 -16
- package/components/Validation/index.d.ts +3 -3
- package/components/Validation/index.js +1 -1
- package/components/Validation/styles.module.scss +18 -18
- package/components/Validation/styles.module.scss.d.ts +10 -10
- package/constants.d.ts +91 -91
- package/hooks/focus-utils.d.ts +6 -6
- package/hooks/useBreakpoint.d.ts +12 -12
- package/hooks/useFocusToggle.d.ts +13 -13
- package/hooks/useFocusTrap.d.ts +3 -3
- package/hooks/useHover.d.ts +11 -11
- package/hooks/useIcons.d.ts +3 -3
- package/hooks/useIntersectionObserver.d.ts +10 -10
- package/hooks/useIsVisible.d.ts +9 -9
- package/hooks/useLayoutEvent.d.ts +8 -8
- package/hooks/usePrevious.d.ts +7 -0
- package/hooks/usePrevious.d.ts.map +1 -0
- package/hooks/useSize.d.ts +8 -8
- package/hooks/useSticky.d.ts +20 -20
- package/hooks/useWindowSize.d.ts +4 -4
- package/index.d.ts +13 -12
- package/index.d.ts.map +1 -1
- package/index.js +1 -1
- package/package.json +1 -1
- package/scss/_body.scss +11 -11
- package/scss/_breakpoints.scss +16 -16
- package/scss/_font-settings.scss +8 -8
- package/scss/_fonts.scss +112 -112
- package/scss/_grid.scss +1 -1
- package/scss/_input.scss +176 -176
- package/scss/_palette.scss +136 -136
- package/scss/_print.scss +176 -176
- package/scss/_reset.scss +13 -13
- package/scss/_spacers.scss +40 -40
- package/scss/_title.scss +59 -59
- package/scss/helsenorge.scss +8 -8
- package/scss/typography.module.scss +154 -154
- package/theme/currys/color.d.ts +3 -3
- package/theme/currys/index.d.ts +2 -2
- package/theme/currys/spacing.d.ts +3 -3
- package/theme/grid.d.ts +20 -20
- package/theme/index.d.ts +98 -98
- package/theme/palette.d.ts +67 -67
- package/theme/spacers.d.ts +18 -18
- package/usePrevious-ae293b10.js +2 -0
- package/usePrevious-ae293b10.js.map +1 -0
- package/utils/debounce.d.ts +7 -7
- package/utils/uuid.d.ts +2 -2
- package/utils/viewport.d.ts +1 -1
- package/AlertSignFill-e607ff43.js +0 -2
- package/AlertSignFill-e607ff43.js.map +0 -1
- package/Button-397ff5a8.js +0 -2
- package/Button-397ff5a8.js.map +0 -1
- package/Check-6291ad09.js +0 -2
- package/Check-6291ad09.js.map +0 -1
- package/Checkbox-acd12b0c.js +0 -2
- package/Checkbox-acd12b0c.js.map +0 -1
- package/ChevronUp-4b6797ef.js +0 -2
- package/ChevronUp-4b6797ef.js.map +0 -1
- package/Close-060173de.js +0 -2
- package/Close-060173de.js.map +0 -1
- package/FormGroup-b2b6efe0.js.map +0 -1
- package/Icon-537c6b21.js +0 -2
- package/Icon-537c6b21.js.map +0 -1
- package/Input-59ca2467.js +0 -2
- package/Input-59ca2467.js.map +0 -1
- package/Modal-3c7f9f93.js +0 -2
- package/Modal-3c7f9f93.js.map +0 -1
- package/Validation-16a8bdcd.js +0 -2
- package/Validation-16a8bdcd.js.map +0 -1
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
export interface CloseProps {
|
|
3
|
-
/** Function is called when user clicks the button */
|
|
4
|
-
onClick?: () => void;
|
|
5
|
-
/** Sets the aria-label of the button */
|
|
6
|
-
ariaLabel?: string;
|
|
7
|
-
/** Sets the data-testid attribute. */
|
|
8
|
-
testId?: string;
|
|
9
|
-
}
|
|
10
|
-
declare const Close: (props: CloseProps) => JSX.Element;
|
|
11
|
-
export default Close;
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export interface CloseProps {
|
|
3
|
+
/** Function is called when user clicks the button */
|
|
4
|
+
onClick?: () => void;
|
|
5
|
+
/** Sets the aria-label of the button */
|
|
6
|
+
ariaLabel?: string;
|
|
7
|
+
/** Sets the data-testid attribute. */
|
|
8
|
+
testId?: string;
|
|
9
|
+
}
|
|
10
|
+
declare const Close: (props: CloseProps) => JSX.Element;
|
|
11
|
+
export default Close;
|
|
12
12
|
//# sourceMappingURL=Close.d.ts.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import Close from './Close';
|
|
2
|
-
export * from './Close';
|
|
3
|
-
export default Close;
|
|
1
|
+
import Close from './Close';
|
|
2
|
+
export * from './Close';
|
|
3
|
+
export default Close;
|
|
4
4
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{C as s}from"../../Close-
|
|
1
|
+
import{C as s}from"../../Close-d81081c8.js";export{C as default}from"../../Close-d81081c8.js";import"react";import"../../palette-f206f488.js";import"../Icons/Icon.js";import"../../_tslib-51c8a283.js";import"../../constants-eb74321e.js";import"../Icons/X.js";import"./styles.module.scss";import"../../useBreakpoint-552af2b9.js";import"../../_rollupPluginBabelHelpers-b8ef6dd9.js";import"../../grid-11a70eb7.js";
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,32 +1,32 @@
|
|
|
1
|
-
@import '../../scss/_spacers.scss';
|
|
2
|
-
@import '../../scss/_palette.scss';
|
|
3
|
-
@import '../../scss/_breakpoints.scss';
|
|
4
|
-
|
|
5
|
-
.close {
|
|
6
|
-
@media (max-width: map-get($grid-breakpoints, sm)) {
|
|
7
|
-
height: 2.375rem;
|
|
8
|
-
width: 2.375rem;
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
height: 3rem;
|
|
12
|
-
width: 3rem;
|
|
13
|
-
padding: 0;
|
|
14
|
-
border: 0;
|
|
15
|
-
background-color: transparent;
|
|
16
|
-
cursor: pointer;
|
|
17
|
-
|
|
18
|
-
&:hover,
|
|
19
|
-
&:active {
|
|
20
|
-
background-color: rgba(88, 170, 187, 0.1);
|
|
21
|
-
}
|
|
22
|
-
&:focus {
|
|
23
|
-
box-shadow: 0px 0px 0px 2px $black;
|
|
24
|
-
background-color: transparent;
|
|
25
|
-
border-radius: 0;
|
|
26
|
-
border: 0;
|
|
27
|
-
outline: none;
|
|
28
|
-
}
|
|
29
|
-
&:hover#{&}:hover{
|
|
30
|
-
background-color: rgba(88, 170, 187, 0.1);
|
|
31
|
-
}
|
|
32
|
-
}
|
|
1
|
+
@import '../../scss/_spacers.scss';
|
|
2
|
+
@import '../../scss/_palette.scss';
|
|
3
|
+
@import '../../scss/_breakpoints.scss';
|
|
4
|
+
|
|
5
|
+
.close {
|
|
6
|
+
@media (max-width: map-get($grid-breakpoints, sm)) {
|
|
7
|
+
height: 2.375rem;
|
|
8
|
+
width: 2.375rem;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
height: 3rem;
|
|
12
|
+
width: 3rem;
|
|
13
|
+
padding: 0;
|
|
14
|
+
border: 0;
|
|
15
|
+
background-color: transparent;
|
|
16
|
+
cursor: pointer;
|
|
17
|
+
|
|
18
|
+
&:hover,
|
|
19
|
+
&:active {
|
|
20
|
+
background-color: rgba(88, 170, 187, 0.1);
|
|
21
|
+
}
|
|
22
|
+
&:focus {
|
|
23
|
+
box-shadow: 0px 0px 0px 2px $black;
|
|
24
|
+
background-color: transparent;
|
|
25
|
+
border-radius: 0;
|
|
26
|
+
border: 0;
|
|
27
|
+
outline: none;
|
|
28
|
+
}
|
|
29
|
+
&:hover#{&}:hover{
|
|
30
|
+
background-color: rgba(88, 170, 187, 0.1);
|
|
31
|
+
}
|
|
32
|
+
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
export type Styles = {
|
|
2
|
-
close: string;
|
|
3
|
-
};
|
|
4
|
-
|
|
5
|
-
export type ClassNames = keyof Styles;
|
|
6
|
-
|
|
7
|
-
declare const styles: Styles;
|
|
8
|
-
|
|
9
|
-
export default styles;
|
|
1
|
+
export type Styles = {
|
|
2
|
+
close: string;
|
|
3
|
+
};
|
|
4
|
+
|
|
5
|
+
export type ClassNames = keyof Styles;
|
|
6
|
+
|
|
7
|
+
declare const styles: Styles;
|
|
8
|
+
|
|
9
|
+
export default styles;
|
|
@@ -1,33 +1,33 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { SvgIcon } from '../Icons';
|
|
3
|
-
import { PaletteNames } from '../../theme/palette';
|
|
4
|
-
export declare enum ExpanderSize {
|
|
5
|
-
small = "small",
|
|
6
|
-
large = "large"
|
|
7
|
-
}
|
|
8
|
-
export declare type ExpanderColors = Extract<PaletteNames, 'banana' | 'blueberry' | 'cherry' | 'kiwi' | 'neutral' | 'plum' | 'white'>;
|
|
9
|
-
interface ExpanderProps {
|
|
10
|
-
/** Sets the trigger title */
|
|
11
|
-
title: string;
|
|
12
|
-
/** Sets the expanded content */
|
|
13
|
-
children?: React.ReactNode;
|
|
14
|
-
/** Sets the size of the expander. Default: ExpanderSize.small */
|
|
15
|
-
size?: ExpanderSize;
|
|
16
|
-
/** Sets the background of the expander. Requires size=ExpanderSize.large. */
|
|
17
|
-
color?: ExpanderColors;
|
|
18
|
-
/** Adds an icon to the expander trigger. Requires size=ExpanderSize.large. */
|
|
19
|
-
svgIcon?: SvgIcon;
|
|
20
|
-
/** Adds an icon to the expander trigger */
|
|
21
|
-
expanded?: boolean;
|
|
22
|
-
/** Removes border to the left of the content. Requires size=ExpanderSize.small. */
|
|
23
|
-
noNestedLine?: boolean;
|
|
24
|
-
/** Stick expander trigger to top of screen while scrolling down */
|
|
25
|
-
sticky?: boolean;
|
|
26
|
-
/** Called when expander is open/closed. */
|
|
27
|
-
onExpand?: (isExpanded: boolean) => void;
|
|
28
|
-
/** Sets the data-testid attribute on the expander button. */
|
|
29
|
-
testId?: string;
|
|
30
|
-
}
|
|
31
|
-
declare const Expander: React.FC<ExpanderProps>;
|
|
32
|
-
export default Expander;
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { SvgIcon } from '../Icons';
|
|
3
|
+
import { PaletteNames } from '../../theme/palette';
|
|
4
|
+
export declare enum ExpanderSize {
|
|
5
|
+
small = "small",
|
|
6
|
+
large = "large"
|
|
7
|
+
}
|
|
8
|
+
export declare type ExpanderColors = Extract<PaletteNames, 'banana' | 'blueberry' | 'cherry' | 'kiwi' | 'neutral' | 'plum' | 'white'>;
|
|
9
|
+
interface ExpanderProps {
|
|
10
|
+
/** Sets the trigger title */
|
|
11
|
+
title: string;
|
|
12
|
+
/** Sets the expanded content */
|
|
13
|
+
children?: React.ReactNode;
|
|
14
|
+
/** Sets the size of the expander. Default: ExpanderSize.small */
|
|
15
|
+
size?: ExpanderSize;
|
|
16
|
+
/** Sets the background of the expander. Requires size=ExpanderSize.large. */
|
|
17
|
+
color?: ExpanderColors;
|
|
18
|
+
/** Adds an icon to the expander trigger. Requires size=ExpanderSize.large. */
|
|
19
|
+
svgIcon?: SvgIcon;
|
|
20
|
+
/** Adds an icon to the expander trigger */
|
|
21
|
+
expanded?: boolean;
|
|
22
|
+
/** Removes border to the left of the content. Requires size=ExpanderSize.small. */
|
|
23
|
+
noNestedLine?: boolean;
|
|
24
|
+
/** Stick expander trigger to top of screen while scrolling down */
|
|
25
|
+
sticky?: boolean;
|
|
26
|
+
/** Called when expander is open/closed. */
|
|
27
|
+
onExpand?: (isExpanded: boolean) => void;
|
|
28
|
+
/** Sets the data-testid attribute on the expander button. */
|
|
29
|
+
testId?: string;
|
|
30
|
+
}
|
|
31
|
+
declare const Expander: React.FC<ExpanderProps>;
|
|
32
|
+
export default Expander;
|
|
33
33
|
//# sourceMappingURL=Expander.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Expander.d.ts","sourceRoot":"","sources":["../../../src/components/Expander/Expander.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAsC,MAAM,OAAO,CAAC;AAC3D,OAAa,EAAY,OAAO,EAAE,MAAM,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"Expander.d.ts","sourceRoot":"","sources":["../../../src/components/Expander/Expander.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAsC,MAAM,OAAO,CAAC;AAC3D,OAAa,EAAY,OAAO,EAAE,MAAM,UAAU,CAAC;AAGnD,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAUnD,oBAAY,YAAY;IACtB,KAAK,UAAU;IACf,KAAK,UAAU;CAChB;AAED,oBAAY,cAAc,GAAG,OAAO,CAAC,YAAY,EAAE,QAAQ,GAAG,WAAW,GAAG,QAAQ,GAAG,MAAM,GAAG,SAAS,GAAG,MAAM,GAAG,OAAO,CAAC,CAAC;AAE9H,UAAU,aAAa;IACrB,6BAA6B;IAC7B,KAAK,EAAE,MAAM,CAAC;IACd,gCAAgC;IAChC,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B,iEAAiE;IACjE,IAAI,CAAC,EAAE,YAAY,CAAC;IACpB,6EAA6E;IAC7E,KAAK,CAAC,EAAE,cAAc,CAAC;IACvB,8EAA8E;IAC9E,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,2CAA2C;IAC3C,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,mFAAmF;IACnF,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,mEAAmE;IACnE,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,2CAA2C;IAC3C,QAAQ,CAAC,EAAE,CAAC,UAAU,EAAE,OAAO,KAAK,IAAI,CAAC;IACzC,6DAA6D;IAC7D,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,QAAA,MAAM,QAAQ,EAAE,KAAK,CAAC,EAAE,CAAC,aAAa,CA0HrC,CAAC;AAEF,eAAe,QAAQ,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import Expander from './Expander';
|
|
2
|
-
export * from './Expander';
|
|
3
|
-
export default Expander;
|
|
1
|
+
import Expander from './Expander';
|
|
2
|
+
export * from './Expander';
|
|
3
|
+
export default Expander;
|
|
4
4
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{_ as e}from"../../_rollupPluginBabelHelpers-b8ef6dd9.js";import t,{useState as
|
|
1
|
+
import{_ as e}from"../../_rollupPluginBabelHelpers-b8ef6dd9.js";import t,{useState as n,useRef as r,useEffect as a}from"react";import{Icon as o}from"../Icons/Icon.js";import{Z as s,A as i,I as d}from"../../constants-eb74321e.js";import{u as c}from"../../useHover-9710204a.js";import{u as l}from"../../usePrevious-ae293b10.js";import p from"./styles.module.scss";import{c as m}from"../../index-9b84fabc.js";import _ from"../Icons/ChevronDown.js";import u from"../Icons/ChevronUp.js";import{B as x}from"../../Button-7e82091f.js";import{a as f}from"../../useSticky-d61d1f0b.js";import"../../_tslib-51c8a283.js";import"../../color-a10c7892.js";import"../../index-0e78dfa0.js";import"../../palette-f206f488.js";import"../../grid-11a70eb7.js";import"../../Loader-bc13d060.js";import"../../uuid-fe7442b7.js";import"../Loader/styles.module.scss";import"../../useWindowSize-750f9b68.js";import"../Button/styles.module.scss";var g;!function(e){e.small="small",e.large="large"}(g||(g={}));export default function(v){var b=v.title,j=v.children,E=v.size,I=void 0===E?g.small:E,y=v.color,h=v.svgIcon,N=v.expanded,k=void 0!==N&&N,z=v.noNestedLine,H=void 0!==z&&z,w=v.sticky,S=void 0!==w&&w,B=v.testId,C=v.onExpand,L=n(k),W=e(L,2),X=W[0],P=W[1],T=l(X),A=r(null),D=r(null),O=r(null),U=c(D).isHovered,Z=f(A,D),q=Z.isOutsideWindow,F=Z.isLeavingWindow,G=Z.offsetHeight,J=Z.contentWidth,K=S&&X&&q;a((function(){k!==X&&P(k)}),[k]),a((function(){C&&X!==!!T&&C(X)}),[X,C]);var M=function(e){return t.createElement("span",{className:m(p.expander__icon,p["expander__icon--".concat(e)])},t.createElement(o,{svgIcon:X?u:_,size:d.XSmall,isHovered:U}))},Q=m(p.expander__trigger,p["expander__trigger--".concat(I)],I===g.large&&p["expander__trigger--".concat(y||"neutral")],I===g.large&&h&&p["expander__trigger--icon"],X&&p["expander__trigger--expanded"],K&&!F&&p["expander__trigger--sticky"],K&&F&&p["expander__trigger--absolute"]),R=m(p.expander__button,X&&p["expander__button--expanded"],K&&!F&&p["expander__button--sticky"],K&&F&&p["expander__button--absolute"]),V=m(p.expander__content,p["expander__content--".concat(I)],I===g.large&&p["expander__content--".concat(y||"neutral")],I===g.large&&h&&p["expander__content--icon"],X&&p["expander__content--expanded"],I===g.small&&!H&&p["expander__content--nested-line"]);return t.createElement("div",{className:p.expander,ref:A,style:{paddingTop:K&&G?"".concat(G,"px"):void 0}},I===g.large?t.createElement("button",{className:Q,style:{zIndex:U||K?s.ExpanderTrigger:void 0,width:K&&J?"".concat(J,"px"):void 0},"aria-expanded":X,ref:D,onClick:function(){return P(!X)},"data-testid":B,"data-analyticsid":i.Expander},I===g.small&&M("left"),h&&t.createElement("span",{className:m(p.expander__icon,p["expander__icon--left"])},t.createElement(o,{svgIcon:h,size:d.XSmall,isHovered:U})),b,I===g.large&&M("right")):t.createElement(x,{variant:"borderless",className:R,"aria-expanded":X,ref:D,onClick:function(){return P(!X)},testId:B,"data-analyticsid":i.Expander},t.createElement(o,{svgIcon:X?u:_,size:d.XSmall}),b),t.createElement("div",{className:V,ref:O},j))}export{g as ExpanderSize};
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,165 +1,165 @@
|
|
|
1
|
-
@import '../../scss/_spacers.scss';
|
|
2
|
-
@import '../../scss/_breakpoints.scss';
|
|
3
|
-
@import '../../scss/_palette.scss';
|
|
4
|
-
@import '../../scss/_font-settings.scss';
|
|
5
|
-
|
|
6
|
-
.expander {
|
|
7
|
-
position: relative;
|
|
8
|
-
width: 100%;
|
|
9
|
-
&__icon {
|
|
10
|
-
display: flex;
|
|
11
|
-
align-items: center;
|
|
12
|
-
&--left {
|
|
13
|
-
margin-right: getSpacer(2xs);
|
|
14
|
-
@media (min-width: map-get($grid-breakpoints, md)) {
|
|
15
|
-
margin-right: getSpacer(s);
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
&--right {
|
|
19
|
-
margin-left: auto;
|
|
20
|
-
padding-left: getSpacer(2xs);
|
|
21
|
-
}
|
|
22
|
-
}
|
|
23
|
-
&__button {
|
|
24
|
-
position: relative;
|
|
25
|
-
&:hover {
|
|
26
|
-
background-color: $blueberry50;
|
|
27
|
-
}
|
|
28
|
-
&--expanded {
|
|
29
|
-
background-color: $blueberry50;
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
&__trigger {
|
|
33
|
-
$trigger: &;
|
|
34
|
-
position: relative;
|
|
35
|
-
display: flex;
|
|
36
|
-
align-items: center;
|
|
37
|
-
border: none;
|
|
38
|
-
outline: none;
|
|
39
|
-
font-size: $font-size-sm;
|
|
40
|
-
line-height: $lineheight-size-sm;
|
|
41
|
-
font-weight: 600;
|
|
42
|
-
@media (min-width: map-get($grid-breakpoints, md)) {
|
|
43
|
-
font-size: $font-size-md;
|
|
44
|
-
line-height: $lineheight-size-md;
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
&--large {
|
|
48
|
-
width: 100%;
|
|
49
|
-
padding: getSpacer(xs) getSpacer(2xs) getSpacer(xs) getSpacer(s);
|
|
50
|
-
|
|
51
|
-
@media (min-width: map-get($grid-breakpoints, md)) {
|
|
52
|
-
padding: getSpacer(xs) getSpacer(s) getSpacer(xs) getSpacer(l);
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
&--icon {
|
|
56
|
-
padding-left: getSpacer(2xs);
|
|
57
|
-
@media (min-width: map-get($grid-breakpoints, md)) {
|
|
58
|
-
padding-left: getSpacer(s);
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
$colors: 'neutral', 'blueberry', 'cherry', 'kiwi', 'banana', 'plum';
|
|
63
|
-
|
|
64
|
-
@each $color in $colors {
|
|
65
|
-
&--#{$color} {
|
|
66
|
-
background-color: map-get($palette-map, #{$color}50);
|
|
67
|
-
&:hover {
|
|
68
|
-
background-color: map-get($palette-map, #{$color}100);
|
|
69
|
-
}
|
|
70
|
-
&:focus {
|
|
71
|
-
box-shadow: 0 0 0 1.5px $neutral600, inset 0 0 0 1.5px $neutral600;
|
|
72
|
-
}
|
|
73
|
-
&#{$trigger}--expanded {
|
|
74
|
-
background-color: map-get($palette-map, #{$color}100);
|
|
75
|
-
&:hover {
|
|
76
|
-
background-color: map-get($palette-map, #{$color}200);
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
// Hvit bakgrunn har egne regler for bakgrunnsfarge, hover og fokus
|
|
83
|
-
&--white {
|
|
84
|
-
background-color: $white;
|
|
85
|
-
&:hover {
|
|
86
|
-
background-color: $neutral100;
|
|
87
|
-
}
|
|
88
|
-
&:focus {
|
|
89
|
-
box-shadow: 0 0 0 1.5px $neutral600, inset 0 0 0 1.5px $neutral600;
|
|
90
|
-
}
|
|
91
|
-
&#{$trigger}--expanded {
|
|
92
|
-
box-shadow: inset 0 0 0 6px $neutral100;
|
|
93
|
-
&:focus {
|
|
94
|
-
box-shadow: 0 0 0 1.5px $neutral600, inset 0 0 0 1.5px $neutral600, inset 0 0 0 6px $neutral100;
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
&__button,
|
|
100
|
-
&__trigger {
|
|
101
|
-
&--sticky {
|
|
102
|
-
position: fixed;
|
|
103
|
-
top: 0;
|
|
104
|
-
}
|
|
105
|
-
&--absolute {
|
|
106
|
-
position: absolute;
|
|
107
|
-
bottom: 0;
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
&__content {
|
|
111
|
-
$content: &;
|
|
112
|
-
display: none;
|
|
113
|
-
width: 100%;
|
|
114
|
-
|
|
115
|
-
&--expanded {
|
|
116
|
-
display: block;
|
|
117
|
-
}
|
|
118
|
-
&--small {
|
|
119
|
-
margin-top: getSpacer(s);
|
|
120
|
-
}
|
|
121
|
-
&--nested-line {
|
|
122
|
-
padding-left: getSpacer(s);
|
|
123
|
-
border-left: solid 3px $neutral200;
|
|
124
|
-
@media (min-width: map-get($grid-breakpoints, md)) {
|
|
125
|
-
margin-left: calc(38px / 2 - 1px); // Halvparten av chevron-ikonets bredde minus halve bredden på border
|
|
126
|
-
padding-left: calc(
|
|
127
|
-
38px / 2 + 12px - 2px
|
|
128
|
-
); // Halvparten av chevron-ikonets bredde, pluss ikonets margin-right på tablet, minus bredden på border
|
|
129
|
-
}
|
|
130
|
-
}
|
|
131
|
-
&--large {
|
|
132
|
-
padding: getSpacer(s) getSpacer(m) getSpacer(l) getSpacer(s);
|
|
133
|
-
|
|
134
|
-
@media (min-width: map-get($grid-breakpoints, md)) {
|
|
135
|
-
padding: getSpacer(m) getSpacer(l) getSpacer(xl) getSpacer(l);
|
|
136
|
-
}
|
|
137
|
-
&#{$content}--icon {
|
|
138
|
-
@media (min-width: map-get($grid-breakpoints, md)) {
|
|
139
|
-
padding-left: 70px;
|
|
140
|
-
}
|
|
141
|
-
}
|
|
142
|
-
}
|
|
143
|
-
&--neutral {
|
|
144
|
-
background-color: $neutral50;
|
|
145
|
-
}
|
|
146
|
-
&--blueberry {
|
|
147
|
-
background-color: $blueberry50;
|
|
148
|
-
}
|
|
149
|
-
&--cherry {
|
|
150
|
-
background-color: $cherry50;
|
|
151
|
-
}
|
|
152
|
-
&--kiwi {
|
|
153
|
-
background-color: $kiwi50;
|
|
154
|
-
}
|
|
155
|
-
&--banana {
|
|
156
|
-
background-color: $banana50;
|
|
157
|
-
}
|
|
158
|
-
&--plum {
|
|
159
|
-
background-color: $plum50;
|
|
160
|
-
}
|
|
161
|
-
&--white {
|
|
162
|
-
background-color: $white;
|
|
163
|
-
}
|
|
164
|
-
}
|
|
165
|
-
}
|
|
1
|
+
@import '../../scss/_spacers.scss';
|
|
2
|
+
@import '../../scss/_breakpoints.scss';
|
|
3
|
+
@import '../../scss/_palette.scss';
|
|
4
|
+
@import '../../scss/_font-settings.scss';
|
|
5
|
+
|
|
6
|
+
.expander {
|
|
7
|
+
position: relative;
|
|
8
|
+
width: 100%;
|
|
9
|
+
&__icon {
|
|
10
|
+
display: flex;
|
|
11
|
+
align-items: center;
|
|
12
|
+
&--left {
|
|
13
|
+
margin-right: getSpacer(2xs);
|
|
14
|
+
@media (min-width: map-get($grid-breakpoints, md)) {
|
|
15
|
+
margin-right: getSpacer(s);
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
&--right {
|
|
19
|
+
margin-left: auto;
|
|
20
|
+
padding-left: getSpacer(2xs);
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
&__button {
|
|
24
|
+
position: relative;
|
|
25
|
+
&:hover {
|
|
26
|
+
background-color: $blueberry50;
|
|
27
|
+
}
|
|
28
|
+
&--expanded {
|
|
29
|
+
background-color: $blueberry50;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
&__trigger {
|
|
33
|
+
$trigger: &;
|
|
34
|
+
position: relative;
|
|
35
|
+
display: flex;
|
|
36
|
+
align-items: center;
|
|
37
|
+
border: none;
|
|
38
|
+
outline: none;
|
|
39
|
+
font-size: $font-size-sm;
|
|
40
|
+
line-height: $lineheight-size-sm;
|
|
41
|
+
font-weight: 600;
|
|
42
|
+
@media (min-width: map-get($grid-breakpoints, md)) {
|
|
43
|
+
font-size: $font-size-md;
|
|
44
|
+
line-height: $lineheight-size-md;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
&--large {
|
|
48
|
+
width: 100%;
|
|
49
|
+
padding: getSpacer(xs) getSpacer(2xs) getSpacer(xs) getSpacer(s);
|
|
50
|
+
|
|
51
|
+
@media (min-width: map-get($grid-breakpoints, md)) {
|
|
52
|
+
padding: getSpacer(xs) getSpacer(s) getSpacer(xs) getSpacer(l);
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
&--icon {
|
|
56
|
+
padding-left: getSpacer(2xs);
|
|
57
|
+
@media (min-width: map-get($grid-breakpoints, md)) {
|
|
58
|
+
padding-left: getSpacer(s);
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
$colors: 'neutral', 'blueberry', 'cherry', 'kiwi', 'banana', 'plum';
|
|
63
|
+
|
|
64
|
+
@each $color in $colors {
|
|
65
|
+
&--#{$color} {
|
|
66
|
+
background-color: map-get($palette-map, #{$color}50);
|
|
67
|
+
&:hover {
|
|
68
|
+
background-color: map-get($palette-map, #{$color}100);
|
|
69
|
+
}
|
|
70
|
+
&:focus {
|
|
71
|
+
box-shadow: 0 0 0 1.5px $neutral600, inset 0 0 0 1.5px $neutral600;
|
|
72
|
+
}
|
|
73
|
+
&#{$trigger}--expanded {
|
|
74
|
+
background-color: map-get($palette-map, #{$color}100);
|
|
75
|
+
&:hover {
|
|
76
|
+
background-color: map-get($palette-map, #{$color}200);
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
// Hvit bakgrunn har egne regler for bakgrunnsfarge, hover og fokus
|
|
83
|
+
&--white {
|
|
84
|
+
background-color: $white;
|
|
85
|
+
&:hover {
|
|
86
|
+
background-color: $neutral100;
|
|
87
|
+
}
|
|
88
|
+
&:focus {
|
|
89
|
+
box-shadow: 0 0 0 1.5px $neutral600, inset 0 0 0 1.5px $neutral600;
|
|
90
|
+
}
|
|
91
|
+
&#{$trigger}--expanded {
|
|
92
|
+
box-shadow: inset 0 0 0 6px $neutral100;
|
|
93
|
+
&:focus {
|
|
94
|
+
box-shadow: 0 0 0 1.5px $neutral600, inset 0 0 0 1.5px $neutral600, inset 0 0 0 6px $neutral100;
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
&__button,
|
|
100
|
+
&__trigger {
|
|
101
|
+
&--sticky {
|
|
102
|
+
position: fixed;
|
|
103
|
+
top: 0;
|
|
104
|
+
}
|
|
105
|
+
&--absolute {
|
|
106
|
+
position: absolute;
|
|
107
|
+
bottom: 0;
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
&__content {
|
|
111
|
+
$content: &;
|
|
112
|
+
display: none;
|
|
113
|
+
width: 100%;
|
|
114
|
+
|
|
115
|
+
&--expanded {
|
|
116
|
+
display: block;
|
|
117
|
+
}
|
|
118
|
+
&--small {
|
|
119
|
+
margin-top: getSpacer(s);
|
|
120
|
+
}
|
|
121
|
+
&--nested-line {
|
|
122
|
+
padding-left: getSpacer(s);
|
|
123
|
+
border-left: solid 3px $neutral200;
|
|
124
|
+
@media (min-width: map-get($grid-breakpoints, md)) {
|
|
125
|
+
margin-left: calc(38px / 2 - 1px); // Halvparten av chevron-ikonets bredde minus halve bredden på border
|
|
126
|
+
padding-left: calc(
|
|
127
|
+
38px / 2 + 12px - 2px
|
|
128
|
+
); // Halvparten av chevron-ikonets bredde, pluss ikonets margin-right på tablet, minus bredden på border
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
&--large {
|
|
132
|
+
padding: getSpacer(s) getSpacer(m) getSpacer(l) getSpacer(s);
|
|
133
|
+
|
|
134
|
+
@media (min-width: map-get($grid-breakpoints, md)) {
|
|
135
|
+
padding: getSpacer(m) getSpacer(l) getSpacer(xl) getSpacer(l);
|
|
136
|
+
}
|
|
137
|
+
&#{$content}--icon {
|
|
138
|
+
@media (min-width: map-get($grid-breakpoints, md)) {
|
|
139
|
+
padding-left: 70px;
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
&--neutral {
|
|
144
|
+
background-color: $neutral50;
|
|
145
|
+
}
|
|
146
|
+
&--blueberry {
|
|
147
|
+
background-color: $blueberry50;
|
|
148
|
+
}
|
|
149
|
+
&--cherry {
|
|
150
|
+
background-color: $cherry50;
|
|
151
|
+
}
|
|
152
|
+
&--kiwi {
|
|
153
|
+
background-color: $kiwi50;
|
|
154
|
+
}
|
|
155
|
+
&--banana {
|
|
156
|
+
background-color: $banana50;
|
|
157
|
+
}
|
|
158
|
+
&--plum {
|
|
159
|
+
background-color: $plum50;
|
|
160
|
+
}
|
|
161
|
+
&--white {
|
|
162
|
+
background-color: $white;
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
}
|
|
@@ -1,42 +1,42 @@
|
|
|
1
|
-
export type Styles = {
|
|
2
|
-
expander: string;
|
|
3
|
-
expander__button: string;
|
|
4
|
-
'expander__button--absolute': string;
|
|
5
|
-
'expander__button--expanded': string;
|
|
6
|
-
'expander__button--sticky': string;
|
|
7
|
-
expander__content: string;
|
|
8
|
-
'expander__content--banana': string;
|
|
9
|
-
'expander__content--blueberry': string;
|
|
10
|
-
'expander__content--cherry': string;
|
|
11
|
-
'expander__content--expanded': string;
|
|
12
|
-
'expander__content--icon': string;
|
|
13
|
-
'expander__content--kiwi': string;
|
|
14
|
-
'expander__content--large': string;
|
|
15
|
-
'expander__content--nested-line': string;
|
|
16
|
-
'expander__content--neutral': string;
|
|
17
|
-
'expander__content--plum': string;
|
|
18
|
-
'expander__content--small': string;
|
|
19
|
-
'expander__content--white': string;
|
|
20
|
-
expander__icon: string;
|
|
21
|
-
'expander__icon--left': string;
|
|
22
|
-
'expander__icon--right': string;
|
|
23
|
-
expander__trigger: string;
|
|
24
|
-
'expander__trigger--absolute': string;
|
|
25
|
-
'expander__trigger--banana': string;
|
|
26
|
-
'expander__trigger--blueberry': string;
|
|
27
|
-
'expander__trigger--cherry': string;
|
|
28
|
-
'expander__trigger--expanded': string;
|
|
29
|
-
'expander__trigger--icon': string;
|
|
30
|
-
'expander__trigger--kiwi': string;
|
|
31
|
-
'expander__trigger--large': string;
|
|
32
|
-
'expander__trigger--neutral': string;
|
|
33
|
-
'expander__trigger--plum': string;
|
|
34
|
-
'expander__trigger--sticky': string;
|
|
35
|
-
'expander__trigger--white': string;
|
|
36
|
-
};
|
|
37
|
-
|
|
38
|
-
export type ClassNames = keyof Styles;
|
|
39
|
-
|
|
40
|
-
declare const styles: Styles;
|
|
41
|
-
|
|
42
|
-
export default styles;
|
|
1
|
+
export type Styles = {
|
|
2
|
+
expander: string;
|
|
3
|
+
expander__button: string;
|
|
4
|
+
'expander__button--absolute': string;
|
|
5
|
+
'expander__button--expanded': string;
|
|
6
|
+
'expander__button--sticky': string;
|
|
7
|
+
expander__content: string;
|
|
8
|
+
'expander__content--banana': string;
|
|
9
|
+
'expander__content--blueberry': string;
|
|
10
|
+
'expander__content--cherry': string;
|
|
11
|
+
'expander__content--expanded': string;
|
|
12
|
+
'expander__content--icon': string;
|
|
13
|
+
'expander__content--kiwi': string;
|
|
14
|
+
'expander__content--large': string;
|
|
15
|
+
'expander__content--nested-line': string;
|
|
16
|
+
'expander__content--neutral': string;
|
|
17
|
+
'expander__content--plum': string;
|
|
18
|
+
'expander__content--small': string;
|
|
19
|
+
'expander__content--white': string;
|
|
20
|
+
expander__icon: string;
|
|
21
|
+
'expander__icon--left': string;
|
|
22
|
+
'expander__icon--right': string;
|
|
23
|
+
expander__trigger: string;
|
|
24
|
+
'expander__trigger--absolute': string;
|
|
25
|
+
'expander__trigger--banana': string;
|
|
26
|
+
'expander__trigger--blueberry': string;
|
|
27
|
+
'expander__trigger--cherry': string;
|
|
28
|
+
'expander__trigger--expanded': string;
|
|
29
|
+
'expander__trigger--icon': string;
|
|
30
|
+
'expander__trigger--kiwi': string;
|
|
31
|
+
'expander__trigger--large': string;
|
|
32
|
+
'expander__trigger--neutral': string;
|
|
33
|
+
'expander__trigger--plum': string;
|
|
34
|
+
'expander__trigger--sticky': string;
|
|
35
|
+
'expander__trigger--white': string;
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
export type ClassNames = keyof Styles;
|
|
39
|
+
|
|
40
|
+
declare const styles: Styles;
|
|
41
|
+
|
|
42
|
+
export default styles;
|