diff --git a/src/Nri/Ui/Checkbox/V3.elm b/src/Nri/Ui/Checkbox/V3.elm index 67ab1854..6c84761e 100644 --- a/src/Nri/Ui/Checkbox/V3.elm +++ b/src/Nri/Ui/Checkbox/V3.elm @@ -63,7 +63,6 @@ type IsSelected type Theme = Square | LockOnInside - | Premium selectedToMaybe : IsSelected -> Maybe Bool @@ -118,13 +117,6 @@ buildCheckbox assets modifierClasses model labelContent = , labelContent = labelContent } - Premium -> - { containerClasses = toClassList (modifierClasses ++ [ "SquareClass" ]) - , labelStyles = premiumLabelStyles assets.checkboxLockOnInside_svg model - , labelClasses = labelClass model.selected - , labelContent = labelContent - } - squareLabelStyles assets model = let @@ -196,45 +188,6 @@ lockLabelStyles image model = ) -premiumLabelStyles : - Asset - -> { a | disabled : Bool } - -> Html.Styled.Attribute msg -premiumLabelStyles image model = - let - baseStyles = - [ -- Positioning - alignItems center - , displayFlex - - -- Focus & Hover - , cursor pointer - , outline none - - -- Icon - , icon - ] - - icon = - after - [ property "content" "''" - , display inlineBlock - , width (px 26) - , height (px 24) - , marginLeft (px 8) - , backgroundImage image - , backgroundRepeat noRepeat - , backgroundPosition Css.center - ] - in - css - (if model.disabled then - opacity (num 0.4) :: baseStyles - else - baseStyles - ) - - labelClass : IsSelected -> Html.Styled.Attribute msg labelClass isSelected = case isSelected of diff --git a/src/Nri/Ui/PremiumCheckbox/V1.elm b/src/Nri/Ui/PremiumCheckbox/V1.elm index 84ed6f55..83982593 100644 --- a/src/Nri/Ui/PremiumCheckbox/V1.elm +++ b/src/Nri/Ui/PremiumCheckbox/V1.elm @@ -49,14 +49,6 @@ premium assets config = PremiumLevel.allowedFor config.contentPremiumLevel config.teacherPremiumLevel - - theme = - if isLocked then - Checkbox.LockOnInside - else if config.contentPremiumLevel /= Free then - Checkbox.Premium - else - Checkbox.Square in Html.div [ css @@ -74,7 +66,11 @@ premium assets config = config.onChange , selected = config.selected , disabled = config.disabled - , theme = theme + , theme = + if isLocked then + Checkbox.LockOnInside + else + Checkbox.Square , noOpMsg = config.noOpMsg } , if