@vtex/faststore-plugin-buyer-portal 1.3.7 → 1.3.9

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.
@@ -0,0 +1,60 @@
1
+ name: Changelog Integrity Check
2
+
3
+ on:
4
+ pull_request:
5
+ branches: [main]
6
+
7
+ jobs:
8
+ check-changelog:
9
+ name: Check Changelog Integrity
10
+ runs-on: ubuntu-latest
11
+ # Skip this check if PR has the 'skip-changelog' label
12
+ if: "!contains(github.event.pull_request.labels.*.name, 'skip-changelog')"
13
+
14
+ steps:
15
+ - name: Checkout code
16
+ uses: actions/checkout@v3
17
+ with:
18
+ fetch-depth: 0 # Fetch all history for comparing changes
19
+
20
+ - name: Set up Node.js
21
+ uses: actions/setup-node@v3
22
+ with:
23
+ node-version: "20"
24
+
25
+ - name: Check for CHANGELOG.md changes
26
+ id: check-changelog-updated
27
+ run: |
28
+ if git diff --name-only origin/${{ github.base_ref }} | grep -q "CHANGELOG.md"; then
29
+ echo "Changelog was updated. ✅"
30
+ echo "updated=true" >> $GITHUB_OUTPUT
31
+ else
32
+ echo "No changes to CHANGELOG.md found. ❌"
33
+ echo "updated=false" >> $GITHUB_OUTPUT
34
+ fi
35
+
36
+ - name: Fail if changelog not updated
37
+ if: steps.check-changelog-updated.outputs.updated == 'false'
38
+ run: |
39
+ # Check if this PR is exempt from requiring changelog updates
40
+ if [[ "${{ contains(github.event.pull_request.labels.*.name, 'documentation') || contains(github.event.pull_request.title, 'docs:') }}" == "true" ]]; then
41
+ echo "This is a documentation change. Skipping changelog check."
42
+ exit 0
43
+ fi
44
+
45
+ echo "Error: No changes to CHANGELOG.md found. Please update the changelog with your changes."
46
+ echo "If this PR doesn't require a changelog entry, add the 'skip-changelog' label."
47
+ exit 1
48
+
49
+ - name: Comment on PR
50
+ if: failure() && github.event_name == 'pull_request'
51
+ uses: actions/github-script@v6
52
+ with:
53
+ github-token: ${{ secrets.GITHUB_TOKEN }}
54
+ script: |
55
+ github.rest.issues.createComment({
56
+ issue_number: context.issue.number,
57
+ owner: context.repo.owner,
58
+ repo: context.repo.repo,
59
+ body: '⚠️ **Changelog check failed!** Please update CHANGELOG.md with your changes. If this PR doesn\'t require a changelog entry, add the `skip-changelog` label.'
60
+ })
package/CHANGELOG.md CHANGED
@@ -7,6 +7,18 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ## [1.3.9] - 2025-10-21
11
+
12
+ ### Added
13
+
14
+ - Add Changelog entry check on actions
15
+
16
+ ## [1.3.8] - 2025-10-17
17
+
18
+ ### Added
19
+
20
+ - Responsiviness to drawer animation
21
+
10
22
  ## [1.3.7] - 2025-10-17
11
23
 
12
24
  ### Added
@@ -56,6 +68,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
56
68
  - Responsiviness to Roles and Roles Details page
57
69
 
58
70
  ### Added
71
+
59
72
  - Responsiviness adjustment to to Buying policies page
60
73
 
61
74
  ### Added
@@ -146,16 +159,15 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
146
159
  - Add CHANGELOG file
147
160
  - Add README file
148
161
 
149
- [unreleased]: https://github.com/vtex/faststore-plugin-buyer-portal/compare/1.3.7...HEAD
162
+ [unreleased]: https://github.com/vtex/faststore-plugin-buyer-portal/compare/v1.3.9...HEAD
150
163
  [1.2.3]: https://github.com/vtex/faststore-plugin-buyer-portal/compare/v1.2.2...1.2.3
151
164
  [1.2.3]: https://github.com/vtex/faststore-plugin-buyer-portal/releases/tag/1.2.3
152
165
  [1.2.4]: https://github.com/vtex/faststore-plugin-buyer-portal/releases/tag/1.2.4
153
166
  [1.3.2]: https://github.com/vtex/faststore-plugin-buyer-portal/releases/tag/1.3.2
154
167
  [1.3.3]: https://github.com/vtex/faststore-plugin-buyer-portal/releases/tag/1.3.3
155
168
  [1.3.4]: https://github.com/vtex/faststore-plugin-buyer-portal/releases/tag/1.3.4
156
-
157
169
  [1.3.5]: https://github.com/vtex/faststore-plugin-buyer-portal/releases/tag/1.3.5
158
-
159
170
  [1.3.6]: https://github.com/vtex/faststore-plugin-buyer-portal/releases/tag/1.3.6
160
-
171
+ [1.3.9]: https://github.com/vtex/faststore-plugin-buyer-portal/compare/v1.3.8...v1.3.9
172
+ [1.3.8]: https://github.com/vtex/faststore-plugin-buyer-portal/compare/v1.3.7...v1.3.8
161
173
  [1.3.7]: https://github.com/vtex/faststore-plugin-buyer-portal/releases/tag/1.3.7
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vtex/faststore-plugin-buyer-portal",
3
- "version": "1.3.7",
3
+ "version": "1.3.9",
4
4
  "description": "A plugin for faststore with buyer portal",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -1,41 +1,44 @@
1
- import { SlideOver } from "@faststore/ui";
1
+ import React from "react";
2
+
3
+ import { SlideOver, useFadeEffect } from "@faststore/ui";
4
+
5
+ import { DrawerProps } from "../../hooks";
2
6
 
3
7
  import { BasicDrawerBody } from "./BasicDrawerBody";
4
8
  import { BasicDrawerButton } from "./BasicDrawerButton";
5
9
  import { BasicDrawerFooter } from "./BasicDrawerFooter";
6
10
  import { BasicDrawerHeading } from "./BasicDrawerHeading";
7
11
 
8
- import type { DrawerProps } from "../../hooks/useDrawerProps";
9
-
10
12
  export type BasicDrawerProps = Omit<DrawerProps, "open"> & {
11
13
  children: React.ReactNode;
12
14
  id?: string;
15
+ isOpen: boolean;
16
+ onDismiss?: () => void;
13
17
  };
14
18
 
15
19
  export const BasicDrawer = ({
16
20
  isOpen,
17
- children,
21
+ onDismiss,
18
22
  id,
23
+ children,
19
24
  ...props
20
25
  }: BasicDrawerProps) => {
26
+ const { fadeOut } = useFadeEffect();
21
27
  return (
22
- <>
23
- {isOpen && (
24
- <SlideOver
25
- size="partial"
26
- direction="rightSide"
27
- isOpen={isOpen}
28
- data-fs-bp-basic-drawer
29
- id={id}
30
- {...props}
31
- >
32
- {children}
33
- </SlideOver>
34
- )}
35
- </>
28
+ <SlideOver
29
+ isOpen={isOpen}
30
+ direction="rightSide"
31
+ size="partial"
32
+ data-fs-bp-basic-drawer
33
+ data-fs-mobile-bottom-sheet
34
+ id={id}
35
+ onDismiss={onDismiss ?? fadeOut}
36
+ {...props}
37
+ >
38
+ {children}
39
+ </SlideOver>
36
40
  );
37
41
  };
38
-
39
42
  BasicDrawer.Heading = BasicDrawerHeading;
40
43
  BasicDrawer.Body = BasicDrawerBody;
41
44
  BasicDrawer.Footer = BasicDrawerFooter;
@@ -10,6 +10,50 @@
10
10
  border-top-left-radius: 1.25rem;
11
11
  border-top-right-radius: 1.25rem;
12
12
 
13
+ &[data-fs-slide-over][data-fs-mobile-bottom-sheet][data-fs-slide-over-sidebar] {
14
+ max-height: 100%;
15
+ }
16
+
17
+ @include media("<=tablet") {
18
+ &[data-fs-slide-over][data-fs-mobile-bottom-sheet] {
19
+ &:not([data-fs-slide-over-sidebar]) {
20
+ left: 0;
21
+ right: 0;
22
+ bottom: 0;
23
+ top: auto;
24
+ width: 100vw;
25
+ max-height: min(85vh, 45rem);
26
+
27
+ border-top-left-radius: var(--fs-spacing-3);
28
+ border-top-right-radius: var(--fs-spacing-3);
29
+ box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.2);
30
+
31
+ will-change: transform;
32
+ backface-visibility: hidden;
33
+ transform: translate3d(0, 100%, 0);
34
+
35
+ transition: transform var(--fs-slide-over-transition-timing) ease;
36
+
37
+ &[data-fs-slide-over-state="in"] {
38
+ transform: translate3d(0, 0, 0);
39
+ }
40
+ &[data-fs-slide-over-state="out"] {
41
+ transform: translate3d(0, 100%, 0);
42
+ }
43
+
44
+ &[data-fs-slide-over-direction="rightSide"][data-fs-slide-over-state="out"],
45
+ &[data-fs-slide-over-direction="leftSide"][data-fs-slide-over-state="out"] {
46
+ transform: translate3d(0, 100%, 0);
47
+ }
48
+
49
+ [data-fs-slide-over][data-fs-mobile-bottom-sheet]
50
+ [data-fs-slide-over-state="out"] {
51
+ transform: translateY(100%);
52
+ }
53
+ }
54
+ }
55
+ }
56
+
13
57
  @include media(">=tablet") {
14
58
  height: 100%;
15
59
  bottom: auto;
@@ -23,6 +23,7 @@ export const SidebarDrawer = ({
23
23
  close={close}
24
24
  {...props}
25
25
  data-fs-slide-over-direction="leftSide"
26
+ data-fs-slide-over-sidebar
26
27
  >
27
28
  <BasicDrawer.Heading
28
29
  title={
@@ -13,4 +13,4 @@ export const LOCAL_STORAGE_LOCATION_EDIT_KEY = "bp_hide_edit_location_confirm";
13
13
  export const LOCAL_STORAGE_RECIPIENT_EDIT_KEY =
14
14
  "bp_hide_edit_recipient_confirm";
15
15
 
16
- export const CURRENT_VERSION = "1.3.7";
16
+ export const CURRENT_VERSION = "1.3.9";