Skip to content

Commit

Permalink
Work in progress
Browse files Browse the repository at this point in the history
  • Loading branch information
RaphaelGauthier committed Aug 3, 2021
1 parent dab60c6 commit 776a2ce
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 7 deletions.
Expand Up @@ -76,7 +76,9 @@ editionTemplate model details isNewRule =
(diff, lengthDiff + diff)

(diffDirectivesPos, diffDirectivesNeg) = getDiffList originRule.directives rule.directives

nbInclude = case originRule.targets of
[Composition (Or i) (Or e)] -> List.length i
targets -> List.length targets
in
div [class "main-container"]
[ div [class "main-header "]
Expand Down Expand Up @@ -117,7 +119,7 @@ editionTemplate model details isNewRule =
[ a[onClick (ChangeTabFocus Groups )]
[ text "Groups"
, span[class "badge badge-secondary badge-resources tooltip-bs"]
[ span [class "nb-resources"] [ text (String.fromInt(List.length rule.targets))]
[ span [class "nb-resources"] [ text (String.fromInt(nbInclude))]
]
]
]
Expand Down
Expand Up @@ -47,7 +47,10 @@ buildRulesTable model =

buildComplianceBar : Float -> String -> Html msg
buildComplianceBar val t =
div[class ("progress-bar progress-bar-" ++ t), style "flex" (fromFloat val)][text ((fromFloat val) ++ "%")]
if val > 0 then
div[class ("progress-bar progress-bar-" ++ t), style "flex" (fromFloat val)][text ((fromFloat val) ++ "%")]
else
text ""

getValueCompliance : Maybe Float -> Float
getValueCompliance f =
Expand Down
Expand Up @@ -43,10 +43,6 @@
width: 100%;
display: inline-block;
}
/* ================ */
.rudder-template .template-sidebar .sidebar-list ul{
padding-left: 15px;
}
/* === OVERRIDE JSTREE === */
.jstree-default li:last-child {
background: transparent;
Expand Down

0 comments on commit 776a2ce

Please sign in to comment.