@faststore/ui 2.2.0-alpha.9 → 2.2.10

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": "@faststore/ui",
3
- "version": "2.2.0-alpha.9",
3
+ "version": "2.2.10",
4
4
  "description": "A lightweight, framework agnostic component library for React",
5
5
  "author": "emersonlaurentino",
6
6
  "license": "MIT",
@@ -48,7 +48,7 @@
48
48
  }
49
49
  ],
50
50
  "dependencies": {
51
- "@faststore/components": "^2.2.0-alpha.9",
51
+ "@faststore/components": "^2.2.10",
52
52
  "include-media": "^1.4.10",
53
53
  "modern-normalize": "^1.1.0",
54
54
  "react-swipeable": "^7.0.0",
@@ -59,8 +59,8 @@
59
59
  "react-dom": "^18.2.0"
60
60
  },
61
61
  "devDependencies": {
62
- "@faststore/eslint-config": "^2.2.0-alpha.1",
63
- "@faststore/shared": "^2.2.0-alpha.1",
62
+ "@faststore/eslint-config": "^2.2.0",
63
+ "@faststore/shared": "^2.2.0",
64
64
  "@size-limit/preset-small-lib": "^7.0.8",
65
65
  "@types/tabbable": "^3.1.1",
66
66
  "babel-loader": "^8.2.5",
@@ -72,5 +72,5 @@
72
72
  "node": "16.18.0",
73
73
  "yarn": "1.19.1"
74
74
  },
75
- "gitHead": "79b9eb42f6f8fb7fdead1141f384c7b826357fa3"
75
+ "gitHead": "a0774a2e911ebcdf167e0456b53ef0be84c58a99"
76
76
  }
@@ -8,9 +8,6 @@
8
8
  --fs-carousel-padding-desktop : var(--fs-spacing-0) calc((100% - var(--fs-grid-max-width))/2) var(--fs-spacing-0);
9
9
 
10
10
  // Item
11
- --fs-carousel-item-width-mobile : 60%;
12
- --fs-carousel-item-width-tablet : 14.2rem;
13
- --fs-carousel-item-width-desktop : 14.4rem;
14
11
  --fs-carousel-item-margin-right : var(--fs-spacing-3);
15
12
 
16
13
  // Controls
@@ -45,7 +42,11 @@
45
42
  // Structural Styles
46
43
  // --------------------------------------------------------
47
44
 
45
+ position: relative;
48
46
  width: inherit;
47
+ display: flex;
48
+ flex-direction: column;
49
+ align-items: center;
49
50
 
50
51
  &:hover {
51
52
  [data-fs-carousel-controls] {
@@ -56,18 +57,27 @@
56
57
  }
57
58
  }
58
59
 
60
+ &[data-fs-carousel-variant='scroll'] [data-fs-carousel-item]{
61
+ flex-shrink: 0;
62
+ }
63
+
59
64
  [data-fs-carousel-controls] {
60
- position: relative;
65
+ position: absolute;
66
+ bottom: 50%;
61
67
  display: flex;
68
+ justify-content: space-between;
69
+ width: 100%;
70
+ margin: auto;
71
+ pointer-events: auto;
62
72
  opacity: 0;
63
- pointer-events: none;
64
- @include media(">=tablet") { margin: var(--fs-carousel-padding-desktop); }
73
+
74
+ @include media(">notebook") {
75
+ width: calc(100% + 2 * var(--fs-control-tap-size) + 2 * var(--fs-spacing-4));
76
+ }
65
77
  }
66
78
 
67
79
  [data-fs-carousel-control] {
68
- bottom: calc(var(--fs-carousel-controls-height) + var(--fs-control-tap-size));
69
80
  cursor: pointer;
70
- transform: translateY(-50%);
71
81
  [data-fs-button-wrapper] {
72
82
  border-radius: var(--fs-carousel-controls-border-radius);
73
83
  box-shadow: var(--fs-carousel-controls-box-shadow);
@@ -75,22 +85,6 @@
75
85
  &:not(:hover) [data-fs-button-wrapper] { background-color: var(--fs-carousel-controls-bkg-color); }
76
86
  }
77
87
 
78
- [data-fs-carousel-control="left"] {
79
- position: absolute;
80
- left: var(--fs-carousel-controls-control-right);
81
- @include media(">notebook") {
82
- left: var(--fs-carousel-controls-control-max-left);
83
- }
84
- }
85
-
86
- [data-fs-carousel-control="right"] {
87
- position: absolute;
88
- right: var(--fs-carousel-controls-control-right);
89
- @include media(">notebook") {
90
- right: var(--fs-carousel-controls-control-max-right);
91
- }
92
- }
93
-
94
88
  [data-fs-icon] {
95
89
  color: var(--fs-carousel-controls-icon-color);
96
90
  }
@@ -109,20 +103,9 @@
109
103
  }
110
104
 
111
105
  [data-fs-carousel-item] {
112
- width: var(--fs-carousel-item-width-mobile);
113
- flex-shrink: 0;
114
-
115
106
  &:not(:last-of-type) {
116
107
  margin-right: var(--fs-carousel-item-margin-right);
117
108
  }
118
-
119
- @include media(">=tablet") {
120
- width: var(--fs-carousel-item-width-tablet);
121
- }
122
-
123
- @include media(">=desktop") {
124
- width: var(--fs-carousel-item-width-desktop);
125
- }
126
109
  }
127
110
 
128
111
  [data-fs-carousel-bullets] {
@@ -135,7 +118,7 @@
135
118
  padding-left: var(--fs-carousel-bullets-padding-left);
136
119
  padding-right: var(--fs-carousel-bullets-padding-right);
137
120
 
138
- @include media(">=tablet") {
121
+ @include media(">tablet") {
139
122
  width: fit-content;
140
123
  align-items: center;
141
124
  justify-content: center;
@@ -153,7 +136,7 @@
153
136
  background-color: var(--fs-carousel-bullet-bkg-color);
154
137
  border-color: transparent;
155
138
  border-radius: 0;
156
- @include media(">=tablet") {
139
+ @include media(">tablet") {
157
140
  width: var(--fs-carousel-bullet-width-desktop);
158
141
  height: var(--fs-carousel-bullet-height-desktop);
159
142
  margin: 0;
@@ -178,6 +178,18 @@
178
178
  }
179
179
  }
180
180
 
181
+ [data-fs-product-details-description-content] {
182
+ font-size: var(--fs-text-size-body);
183
+ line-height: 1.5;
184
+ /**
185
+ * display: contents allows you to remove an element from the box tree but still keep its contents
186
+ * It doesn't have padding or margin, for example.
187
+ *
188
+ * https://blogs.igalia.com/mrego/2018/01/11/display-contents-is-coming/
189
+ */
190
+ display: contents;
191
+ }
192
+
181
193
  [data-fs-image-gallery="with-selector"] ~ [data-fs-product-description] {
182
194
  @include media(">=notebook") {
183
195
  grid-column: 2 / 9;
@@ -13,6 +13,7 @@
13
13
  main {
14
14
  display: flex;
15
15
  flex-direction: column;
16
+ overflow: hidden;
16
17
  }
17
18
 
18
19
  .layout__section {