Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
coopwire-hypothesis
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
孙灵跃 Leon Sun
coopwire-hypothesis
Commits
fba36b83
Commit
fba36b83
authored
Jun 24, 2020
by
Lyza Danger Gardner
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Refactor styling of VersionInfo and related HelpPanel components
parent
9b5c2031
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
26 additions
and
24 deletions
+26
-24
version-info.js
src/sidebar/components/version-info.js
+2
-2
layout.scss
src/styles/mixins/layout.scss
+5
-3
reset.scss
src/styles/reset.scss
+3
-0
help-panel.scss
src/styles/sidebar/components/help-panel.scss
+2
-0
tutorial.scss
src/styles/sidebar/components/tutorial.scss
+2
-5
version-info.scss
src/styles/sidebar/components/version-info.scss
+7
-14
util.scss
src/styles/util.scss
+5
-0
No files found.
src/sidebar/components/version-info.js
View file @
fba36b83
...
...
@@ -20,7 +20,7 @@ function VersionInfo({ toastMessenger, versionData }) {
};
return
(
<
div
>
<
div
className
=
"u-vertical-rhythm"
>
<
dl
className
=
"version-info"
>
<
dt
className
=
"version-info__key"
>
Version
<
/dt
>
<
dd
className
=
"version-info__value"
>
{
versionData
.
version
}
<
/dd
>
...
...
@@ -35,7 +35,7 @@ function VersionInfo({ toastMessenger, versionData }) {
<
dt
className
=
"version-info__key"
>
Date
<
/dt
>
<
dd
className
=
"version-info__value"
>
{
versionData
.
timestamp
}
<
/dd
>
<
/dl
>
<
div
className
=
"
version-info__actions
"
>
<
div
className
=
"
u-layout-row--justify-center
"
>
<
Button
buttonText
=
"Copy version details"
onClick
=
{
copyVersionData
}
...
...
src/styles/mixins/layout.scss
View file @
fba36b83
...
...
@@ -70,12 +70,14 @@
/**
* Establish a vertical (margin) rhythm for this element's immediate
* children (i.e. put equal space between children). Currently set to 1em.
* children (i.e. put equal space between children).
*
* @param $size [var.$layout-margin--medium]: Spacing size (padding)
* @FIXME Find workaround for SvgIcon exception
*/
@mixin
vertical-rhythm
{
@mixin
vertical-rhythm
(
$size
:
var
.
$layout-margin
)
{
&
>
*
+
*
:not
([
class
*=
'svg-icon--inline'
])
{
margin-top
:
var
.
$layout-margin
;
margin-top
:
$size
;
}
}
...
...
src/styles/reset.scss
View file @
fba36b83
...
...
@@ -81,6 +81,9 @@ img::-moz-selection {
ul
,
ol
,
dl
,
dd
,
dt
,
li
{
@include
reset
.
reset-box-model
;
}
...
...
src/styles/sidebar/components/help-panel.scss
View file @
fba36b83
@use
"../../mixins/buttons"
;
@use
"../../mixins/layout"
;
@use
"../../mixins/molecules"
;
@use
"../../mixins/utils"
;
@use
"../../variables"
as
var
;
...
...
@@ -12,6 +13,7 @@
&
__subcontent
{
@include
utils
.
border-top
;
@include
utils
.
border-bottom
;
@include
layout
.
vertical-space
;
a
{
text-decoration
:
underline
;
...
...
src/styles/sidebar/components/tutorial.scss
View file @
fba36b83
@use
"../../variables"
as
var
;
@use
"../../mixins/layout"
;
@use
"../../mixins/utils"
;
.tutorial
{
&
__list
{
padding-left
:
2em
;
}
&
__item
{
margin
:
var
.
$layout-margin--small
0
;
@include
layout
.
vertical-rhythm
(
var
.
$layout-margin--small
);
}
&
__icon
{
...
...
src/styles/sidebar/components/version-info.scss
View file @
fba36b83
...
...
@@ -2,28 +2,21 @@
@use
"../../mixins/layout"
;
.version-info
{
margin-top
:
var
.
$layout-margin--small
;
@include
layout
.
row
;
// Allow multiple lines of content
flex-wrap
:
wrap
;
&
__key
{
float
:
left
;
width
:
8em
;
margin-bottom
:
var
.
$layout-margin--small
;
padding-right
:
var
.
$layout-margin
;
line-height
:
1
.25em
;
flex-basis
:
25%
;
text-align
:
right
;
font-weight
:
500
;
color
:
var
.
$color-text
;
}
&
__value
{
margin-bottom
:
var
.
$layout-margin--small
;
margin-left
:
8em
;
margin-left
:
1em
;
// Space between key and value
flex-basis
:
70%
;
flex-grow
:
1
;
overflow-wrap
:
break-word
;
// Keep really long userids from overflowing
color
:
var
.
$color-text-light
;
}
&
__actions
{
@include
layout
.
row
(
center
);
padding-bottom
:
var
.
$layout-margin--small
;
}
}
src/styles/util.scss
View file @
fba36b83
...
...
@@ -29,6 +29,11 @@
@include
layout
.
row
(
$justify
:
right
);
}
// Establish a row flex container that centers its children
.u-layout-row--justify-center
{
@include
layout
.
row
(
$justify
:
center
);
}
// Use this class to make an element in a flex container "stretchy" and grow
// when there is extra space available.
.u-stretch
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment