Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
fc-pregmod
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
pregmodfan
fc-pregmod
Commits
39b997bd
Commit
39b997bd
authored
3 years ago
by
lowercasedonkey
Browse files
Options
Downloads
Patches
Plain Diff
fixes
parent
b48477ea
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!9370
Make row titles in RA Summary sticky
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
css/rulesAssistant/raSummary.css
+7
-9
7 additions, 9 deletions
css/rulesAssistant/raSummary.css
src/js/rulesAssistantSummary.js
+4
-5
4 additions, 5 deletions
src/js/rulesAssistantSummary.js
with
11 additions
and
14 deletions
css/rulesAssistant/raSummary.css
+
7
−
9
View file @
39b997bd
...
@@ -3,20 +3,17 @@
...
@@ -3,20 +3,17 @@
height
:
90vh
height
:
90vh
}
}
.ra-sum
{
table
.ra-sum
{
text-align
:
left
;
text-align
:
left
;
border-collapse
:
separate
;
border-collapse
:
separate
;
empty-cells
:
hide
;
empty-cells
:
hide
;
border
:
1px
solid
grey
;
}
}
.
ra-sum
:nth-child
(
even
)
{
/*
ra-sum:nth-child(even) {
background-color: #f2f2f2;
background-color: #f2f2f2;
}
}*/
td
.ra-sum
{
.ra-sum-cell
{
border
:
1px
solid
grey
;
border-style
:
solid
;
border
:
1px
;
border-color
:
grey
;
}
}
tr
.ra-sum.header
{
tr
.ra-sum.header
{
...
@@ -24,6 +21,7 @@ tr.ra-sum.header {
...
@@ -24,6 +21,7 @@ tr.ra-sum.header {
top
:
0px
;
top
:
0px
;
z-index
:
2
;
z-index
:
2
;
background
:
#111
;
background
:
#111
;
border
:
inherit
}
}
th
.ra-sum.first-header-cell
{
th
.ra-sum.first-header-cell
{
...
...
This diff is collapsed.
Click to expand it.
src/js/rulesAssistantSummary.js
+
4
−
5
View file @
39b997bd
...
@@ -28,7 +28,7 @@ new App.DomPassage("Rules Assistant Summary", () => {
...
@@ -28,7 +28,7 @@ new App.DomPassage("Rules Assistant Summary", () => {
/* make rest of row title */
/* make rest of row title */
for
(
const
rule
of
rules
)
{
for
(
const
rule
of
rules
)
{
App
.
UI
.
DOM
.
appendNewElement
(
"
th
"
,
header
,
rule
.
name
,
"
ra-sum-cell
"
);
App
.
UI
.
DOM
.
appendNewElement
(
"
th
"
,
header
,
rule
.
name
);
}
}
const
setters
=
rules
.
map
(
r
=>
r
.
set
);
const
setters
=
rules
.
map
(
r
=>
r
.
set
);
...
@@ -87,12 +87,11 @@ new App.DomPassage("Rules Assistant Summary", () => {
...
@@ -87,12 +87,11 @@ new App.DomPassage("Rules Assistant Summary", () => {
if
(
!
cells
.
some
(
v
=>
v
!==
null
))
{
// skip empty rows
if
(
!
cells
.
some
(
v
=>
v
!==
null
))
{
// skip empty rows
return
;
return
;
}
}
const
row
=
App
.
UI
.
DOM
.
makeElement
(
"
tr
"
);
const
row
=
App
.
UI
.
DOM
.
makeElement
(
"
tr
"
,
null
,
"
ra-sum
"
);
function
ruleSetValueToString
(
v
)
{
function
ruleSetValueToString
(
v
)
{
if
(
typeof
v
===
'
object
'
)
{
if
(
typeof
v
===
'
object
'
)
{
if
(
v
.
hasOwnProperty
(
'
cond
'
)
&&
v
.
hasOwnProperty
(
'
val
'
))
{
if
(
v
.
hasOwnProperty
(
'
cond
'
)
&&
v
.
hasOwnProperty
(
'
val
'
))
{
console
.
log
(
v
)
return
`
${
v
.
cond
}
${
v
.
val
}
`
;
return
`
${
v
.
cond
}
${
v
.
val
}
`
;
}
else
if
(
v
.
hasOwnProperty
(
'
min
'
)
&&
v
.
hasOwnProperty
(
'
max
'
))
{
}
else
if
(
v
.
hasOwnProperty
(
'
min
'
)
&&
v
.
hasOwnProperty
(
'
max
'
))
{
return
`
${
v
.
min
}
to
${
v
.
max
}
`
;
return
`
${
v
.
min
}
to
${
v
.
max
}
`
;
...
@@ -103,10 +102,10 @@ new App.DomPassage("Rules Assistant Summary", () => {
...
@@ -103,10 +102,10 @@ new App.DomPassage("Rules Assistant Summary", () => {
return
`
${
v
}
`
;
return
`
${
v
}
`
;
}
}
App
.
UI
.
DOM
.
appendNewElement
(
"
td
"
,
row
,
path
.
join
(
'
.
'
),
[
"
ra-sum
"
,
"
row-title
"
,
"
ra-sum-cell
"
]);
App
.
UI
.
DOM
.
appendNewElement
(
"
td
"
,
row
,
path
.
join
(
'
.
'
),
[
"
ra-sum
"
,
"
row-title
"
]);
for
(
const
cell
of
cells
)
{
for
(
const
cell
of
cells
)
{
const
content
=
cell
!==
null
?
ruleSetValueToString
(
cell
)
:
null
;
const
content
=
cell
!==
null
?
ruleSetValueToString
(
cell
)
:
null
;
App
.
UI
.
DOM
.
appendNewElement
(
"
td
"
,
row
,
content
,
"
ra-sum
-cell
"
);
App
.
UI
.
DOM
.
appendNewElement
(
"
td
"
,
row
,
content
,
"
ra-sum
"
);
}
}
table
.
append
(
row
);
table
.
append
(
row
);
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment