@woosmap/ui 2.16.0 → 2.17.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@woosmap/ui",
3
- "version": "2.16.0",
3
+ "version": "2.17.0",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/WebGeoServices/ui.git"
@@ -94,6 +94,7 @@ Button.propTypes = {
94
94
  'tab',
95
95
  'tab--action',
96
96
  'tab--pills',
97
+ 'sidebar-link',
97
98
  ]),
98
99
  isLoading: PropTypes.bool,
99
100
  active: PropTypes.bool,
@@ -15,6 +15,9 @@ const Template = (args) => {
15
15
  return (
16
16
  <div className="flex-column mbib">
17
17
  <Button label={label} isLoading={isLoading} active={loading} />
18
+ <div className="flex mbi">
19
+ <Button active type="sidebar-link" icon="add" />
20
+ </div>
18
21
  <div className="flex mbi">
19
22
  <Button icon="add" />
20
23
  <Button label={label} />
@@ -6,7 +6,7 @@
6
6
  &.active
7
7
  cursor default
8
8
  &--icon
9
- &:not(.btn--link):not(.btn--link-primary):not(.btn--link-info):not(.btn--link-flex):not(.btn--link-flex-info):not(.btn--group)
9
+ &:not(.btn--link):not(.btn--link-primary):not(.btn--link-info):not(.btn--link-flex):not(.btn--link-flex-info):not(.btn--group):not(.btn--sidebar-link)
10
10
  sq()
11
11
  btn()
12
12
  justify-content center
@@ -147,7 +147,6 @@
147
147
  color $light
148
148
  .icon
149
149
  fill $light
150
-
151
150
  &--dropdown-item
152
151
  flexBtn()
153
152
  ellipsis()
@@ -301,10 +300,10 @@
301
300
 
302
301
 
303
302
  &--has-icon
304
- &:not(.btn--icon):not(.btn--link):not(.btn--link-primary):not(.btn--link-info):not(.btn--link-flex):not(.btn--link-flex-info):not(.btn--loading):not(.btn--mini):not(.btn--small):not(.btn--large):not(.btn--dropdown-item):not(.btn--tab)
303
+ &:not(.btn--icon):not(.btn--link):not(.btn--link-primary):not(.btn--link-info):not(.btn--link-flex):not(.btn--link-flex-info):not(.btn--loading):not(.btn--mini):not(.btn--small):not(.btn--large):not(.btn--dropdown-item):not(.btn--tab):not(.btn--sidebar-link)
305
304
  padding 0 $padding 0 $padding - .6
306
305
  &--loading
307
- &:not(.btn--icon):not(.btn--mini):not(.btn--small):not(.btn--large)
306
+ &:not(.btn--icon):not(.btn--mini):not(.btn--small):not(.btn--large):not(.btn--sidebar-link)
308
307
  padding-left $padding - .4
309
308
  &:hover
310
309
  &.btn--important
@@ -469,6 +468,23 @@
469
468
  .btn
470
469
  border-radius 0 $borderRadius $borderRadius 0 !important
471
470
  border-left .1rem solid $light30 !important
471
+ &--sidebar-link
472
+ trans()
473
+ flexAxis()
474
+ sq($sidebarButtonSize)
475
+ .icon
476
+ fill $light
477
+ &:hover
478
+ background-color $dark15
479
+ .icon
480
+ fill $light
481
+ &.active
482
+ cursor default
483
+ background-color $dark20
484
+ &:hover
485
+ background-color $dark20
486
+ .icon
487
+ fill $light
472
488
  &--small
473
489
  buttonSmall()
474
490
  &.btn--group
@@ -4,6 +4,7 @@ $fontSizeSmall = $fontSize - .2
4
4
  $fontSizeMini = $fontSize - .4
5
5
  $fontWeight = 400
6
6
 
7
+
7
8
  $title = $fontSize + .6
8
9
  $title2 = $fontSize + .4
9
10
  $title3 = $fontSize + .3
@@ -17,6 +18,8 @@ $borderRadius = .6rem
17
18
 
18
19
  $padding = 1.2rem
19
20
 
21
+ $sidebarButtonSize = 5rem
22
+
20
23
  $buttonHeight = 3.8rem
21
24
  $buttonPadding = 0 $padding 0 $padding
22
25
  $buttonFontSize = $fontSize
@@ -71,7 +74,6 @@ $panelWidth = 36rem
71
74
  $panelpadding = 2.4rem
72
75
  $panelHeaderHeight = $contentHeaderHeight
73
76
 
74
-
75
77
  // modal
76
78
  $modalWidth = 70rem
77
79
  $modalPadding = 2.4rem