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
5369f3e4
Unverified
Commit
5369f3e4
authored
Jun 26, 2020
by
Lyza Gardner
Committed by
GitHub
Jun 26, 2020
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #2279 from hypothesis/change-margin-var-name
Change `margin` SASS var names for clarity
parents
4eeb2f01
01c1de46
Changes
17
Hide whitespace changes
Inline
Side-by-side
Showing
17 changed files
with
42 additions
and
42 deletions
+42
-42
layout.scss
src/styles/mixins/layout.scss
+4
-4
molecules.scss
src/styles/mixins/molecules.scss
+4
-4
annotation-body.scss
src/styles/sidebar/components/annotation-body.scss
+1
-1
annotation-header.scss
src/styles/sidebar/components/annotation-header.scss
+1
-1
annotation-license.scss
src/styles/sidebar/components/annotation-license.scss
+2
-2
annotation-publish-control.scss
...styles/sidebar/components/annotation-publish-control.scss
+2
-2
annotation-share-control.scss
src/styles/sidebar/components/annotation-share-control.scss
+2
-2
focused-mode-header.scss
src/styles/sidebar/components/focused-mode-header.scss
+2
-2
selection-tabs.scss
src/styles/sidebar/components/selection-tabs.scss
+1
-1
tag-editor.scss
src/styles/sidebar/components/tag-editor.scss
+6
-6
tag-list.scss
src/styles/sidebar/components/tag-list.scss
+3
-3
thread-list.scss
src/styles/sidebar/components/thread-list.scss
+1
-1
thread.scss
src/styles/sidebar/components/thread.scss
+4
-4
toast-messages.scss
src/styles/sidebar/components/toast-messages.scss
+2
-2
top-bar.scss
src/styles/sidebar/components/top-bar.scss
+2
-2
tutorial.scss
src/styles/sidebar/components/tutorial.scss
+1
-1
variables.scss
src/styles/variables.scss
+4
-4
No files found.
src/styles/mixins/layout.scss
View file @
5369f3e4
...
...
@@ -72,10 +72,10 @@
* Establish a vertical (margin) rhythm for this element's immediate
* children (i.e. put equal space between children).
*
* @param $size [var.$layout-
margin
--medium]: Spacing size (padding)
* @param $size [var.$layout-
space
--medium]: Spacing size (padding)
* @FIXME Find workaround for SvgIcon exception
*/
@mixin
vertical-rhythm
(
$size
:
var
.
$layout-
margin
)
{
@mixin
vertical-rhythm
(
$size
:
var
.
$layout-
space
)
{
&
>
*
+
*
:not
([
class
*=
'svg-icon--inline'
])
{
margin-top
:
$size
;
}
...
...
@@ -84,9 +84,9 @@
/**
* Establish vertical space outside of elements in the container
*
* @param $size [var.$layout-
margin
--medium]: Spacing size (padding)
* @param $size [var.$layout-
space
--medium]: Spacing size (padding)
*/
@mixin
vertical-space
(
$size
:
var
.
$layout-
margin
--medium
)
{
@mixin
vertical-space
(
$size
:
var
.
$layout-
space
--medium
)
{
padding-top
:
$size
;
padding-bottom
:
$size
;
}
src/styles/mixins/molecules.scss
View file @
5369f3e4
...
...
@@ -23,7 +23,7 @@
@mixin
card
{
@include
card-frame
;
@include
layout
.
vertical-rhythm
;
padding
:
var
.
$layout-
margin
;
padding
:
var
.
$layout-
space
;
&
:hover
,
&
.is-focused
{
...
...
@@ -79,7 +79,7 @@
border-left
:
3px
solid
var
.
$color-border
;
color
:
var
.
$color-text-light
;
font-style
:
italic
;
padding
:
0
var
.
$layout-
margin
;
padding
:
0
var
.
$layout-
space
;
// Prevent long URLs etc. in quote causing overflow
overflow-wrap
:
break-word
;
...
...
@@ -99,11 +99,11 @@
&
__header
{
@include
layout
.
row
(
$align
:
center
);
@include
utils
.
border-bottom
;
padding-bottom
:
var
.
$layout-
margin
;
padding-bottom
:
var
.
$layout-
space
;
}
&
__header-icon
{
margin-right
:
var
.
$layout-
margin
--small
;
margin-right
:
var
.
$layout-
space
--small
;
}
&
__title
{
...
...
src/styles/sidebar/components/annotation-body.scss
View file @
5369f3e4
...
...
@@ -11,7 +11,7 @@
.annotation-body__collapse-toggle
{
@include
layout
.
row
(
right
);
@include
layout
.
vertical-space
(
var
.
$layout-
margin
--small
);
@include
layout
.
vertical-space
(
var
.
$layout-
space
--small
);
.annotation-body__collapse-toggle-button
{
@include
buttons
.
button--labeled
;
...
...
src/styles/sidebar/components/annotation-header.scss
View file @
5369f3e4
...
...
@@ -19,7 +19,7 @@
&
__reply-toggle
{
@include
buttons
.
button--link
;
padding
:
0
var
.
$layout-
margin
--small
;
padding
:
0
var
.
$layout-
space
--small
;
}
// Timestamps are right aligned in a flex row
...
...
src/styles/sidebar/components/annotation-license.scss
View file @
5369f3e4
...
...
@@ -6,7 +6,7 @@
@include
utils
.
font--small
;
@include
utils
.
border-top
;
// Space between border and text content
padding-top
:
var
.
$layout-
margin
--small
;
padding-top
:
var
.
$layout-
space
--small
;
// Container with two icons (representing CC licenses)
// with a very small amount of spacing between them
...
...
@@ -14,6 +14,6 @@
@include
layout
.
row
;
@include
layout
.
horizontal-rhythm
(
1px
);
// Add space before text
margin-right
:
var
.
$layout-
margin
--xsmall
;
margin-right
:
var
.
$layout-
space
--xsmall
;
}
}
src/styles/sidebar/components/annotation-publish-control.scss
View file @
5369f3e4
...
...
@@ -34,8 +34,8 @@
&
-cancel
{
@include
buttons
.
button--labeled
;
padding-right
:
var
.
$layout-
margin
--small
;
padding-left
:
var
.
$layout-
margin
--small
;
padding-right
:
var
.
$layout-
space
--small
;
padding-left
:
var
.
$layout-
space
--small
;
&
__icon
{
margin
:
0
;
...
...
src/styles/sidebar/components/annotation-share-control.scss
View file @
5369f3e4
...
...
@@ -19,7 +19,7 @@
&
__icon-button
{
@include
buttons
.
button--input
;
padding
:
var
.
$layout-
margin--xsmall
var
.
$layout-margin
--small
;
padding
:
var
.
$layout-
space--xsmall
var
.
$layout-space
--small
;
}
&
__form-input
{
...
...
@@ -30,7 +30,7 @@
&
__permissions
{
@include
utils
.
font--small
;
margin
:
var
.
$layout-
margin
--small
0
;
margin
:
var
.
$layout-
space
--small
0
;
}
&
__arrow
{
...
...
src/styles/sidebar/components/focused-mode-header.scss
View file @
5369f3e4
...
...
@@ -17,8 +17,8 @@
font-weight
:
300
;
// TODO cleanup
padding
:
var
.
$layout-
margin
--small
;
margin-bottom
:
var
.
$layout-
margin
;
padding
:
var
.
$layout-
space
--small
;
margin-bottom
:
var
.
$layout-
space
;
&
__btn
{
// TODO use Button component
...
...
src/styles/sidebar/components/selection-tabs.scss
View file @
5369f3e4
...
...
@@ -21,7 +21,7 @@
.selection-tabs__icon
{
color
:
var
.
$grey-mid
;
margin
:
0
var
.
$layout-
margin
--xsmall
;
margin
:
0
var
.
$layout-
space
--xsmall
;
}
.selection-tabs--theme-clean
{
...
...
src/styles/sidebar/components/tag-editor.scss
View file @
5369f3e4
...
...
@@ -5,7 +5,7 @@
@use
"../../variables"
as
var
;
.tag-editor
{
margin
:
var
.
$layout-
margin
--small
0
;
margin
:
var
.
$layout-
space
--small
0
;
&
__input
{
@include
forms
.
form-input
;
...
...
@@ -15,13 +15,13 @@
&
__tags
{
@include
layout
.
row
;
flex-wrap
:
wrap
;
margin
:
var
.
$layout-
margin
--small
0
;
margin
:
var
.
$layout-
space
--small
0
;
}
&
__item
{
@include
layout
.
row
;
margin
:
var
.
$layout-
margin--xsmall
var
.
$layout-margin
--small
var
.
$layout-
margin
--small
0
;
margin
:
var
.
$layout-
space--xsmall
var
.
$layout-space
--small
var
.
$layout-
space
--small
0
;
}
&
__edit
{
...
...
@@ -30,7 +30,7 @@
background
:
var
.
$grey-1
;
border-radius
:
var
.
$border-radius
0
0
var
.
$border-radius
;
border-right-width
:
0
;
padding
:
2px
var
.
$layout-
margin
--small
;
padding
:
2px
var
.
$layout-
space
--small
;
}
&
__delete
{
...
...
@@ -38,7 +38,7 @@
@include
utils
.
border
;
color
:
var
.
$grey-mid
;
background-color
:
var
.
$grey-1
;
padding
:
0
var
.
$layout-
margin
--small
;
padding
:
0
var
.
$layout-
space
--small
;
border-radius
:
0
var
.
$border-radius
var
.
$border-radius
0
;
&
:hover
{
...
...
src/styles/sidebar/components/tag-list.scss
View file @
5369f3e4
...
...
@@ -9,9 +9,9 @@
&
__item
{
@include
utils
.
border
;
margin
:
var
.
$layout-
margin--xsmall
var
.
$layout-margin
--small
var
.
$layout-
margin
--xsmall
0
;
padding
:
2px
var
.
$layout-
margin
--small
;
margin
:
var
.
$layout-
space--xsmall
var
.
$layout-space
--small
var
.
$layout-
space
--xsmall
0
;
padding
:
2px
var
.
$layout-
space
--small
;
background
:
var
.
$grey-0
;
border-radius
:
var
.
$border-radius
;
}
...
...
src/styles/sidebar/components/thread-list.scss
View file @
5369f3e4
@use
"../../variables"
as
var
;
.thread-list__card
{
margin-bottom
:
var
.
$layout-
margin
;
margin-bottom
:
var
.
$layout-
space
;
}
src/styles/sidebar/components/thread.scss
View file @
5369f3e4
...
...
@@ -6,19 +6,19 @@
@include
layout
.
row
;
&
--reply
{
margin-top
:
var
.
$layout-
margin
--small
;
margin-top
:
var
.
$layout-
space
--small
;
}
&
--reply
&
__content
{
margin-left
:
var
.
$layout-
margin
;
margin-left
:
var
.
$layout-
space
;
}
&
__children
{
margin-left
:
-1
*
var
.
$layout-
margin
;
margin-left
:
-1
*
var
.
$layout-
space
;
}
&
__unavailable-message
{
margin
:
0
var
.
$layout-
margin
;
margin
:
0
var
.
$layout-
space
;
}
// Left "channel" of thread
...
...
src/styles/sidebar/components/toast-messages.scss
View file @
5369f3e4
...
...
@@ -8,7 +8,7 @@
z-index
:
1
;
left
:
0
;
width
:
100%
;
padding
:
0
var
.
$layout-
margin
--small
;
padding
:
0
var
.
$layout-
space
--small
;
@include
responsive
.
tablet-and-up
{
// When displaying in a wider viewport (desktop/tablet outside of sidebar)
...
...
@@ -78,7 +78,7 @@
}
&
__message
{
padding
:
var
.
$layout-
margin
;
padding
:
var
.
$layout-
space
;
width
:
100%
;
}
...
...
src/styles/sidebar/components/top-bar.scss
View file @
5369f3e4
...
...
@@ -52,7 +52,7 @@
}
&
__menu-label
{
padding
:
var
.
$layout-
margin
--xsmall
;
padding
:
var
.
$layout-
space
--xsmall
;
}
}
...
...
@@ -63,7 +63,7 @@
.top-bar__login-button
{
@include
buttons
.
button
;
@include
utils
.
font--large
;
padding
:
0
var
.
$layout-
margin
--xsmall
;
padding
:
0
var
.
$layout-
space
--xsmall
;
color
:
var
.
$color-brand
;
&
:hover
{
...
...
src/styles/sidebar/components/tutorial.scss
View file @
5369f3e4
...
...
@@ -4,7 +4,7 @@
.tutorial
{
&
__list
{
@include
layout
.
vertical-rhythm
(
var
.
$layout-
margin
--small
);
@include
layout
.
vertical-rhythm
(
var
.
$layout-
space
--small
);
}
&
__icon
{
...
...
src/styles/variables.scss
View file @
5369f3e4
...
...
@@ -83,10 +83,10 @@ $touch-input-font-size: 16px;
// Layout margins
// -------------------------
$layout-h-margin
:
15px
;
// Legacy
$layout-
margin
:
1em
;
$layout-
margin--medium
:
$layout-h-margin
;
$layout-
margin--small
:
$layout-h-margin
/
2
;
$layout-
margin--xsmall
:
$layout-h-margin
/
4
;
$layout-
space
:
1em
;
$layout-
space--xsmall
:
$layout-space
/
4
;
$layout-
space--small
:
$layout-space
/
2
;
$layout-
space--medium
:
$layout-space
;
// Minimum recommended size for tap targets on mobile.
// This value originated from Apple's Human Interface Guidelines.
...
...
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