From 7e41a5c7d9111a0e7c80dde4ce50ecf018bf6b3b Mon Sep 17 00:00:00 2001 From: Ashley Osuna Date: Fri, 14 Aug 2026 11:29:46 -0700 Subject: [PATCH 01/20] feat(PartnerInfoModal): displaying firstName and lastName inputs when either is missing from the user --- .../PartnerInfoModal.stories.tsx | 4 ++ .../sqm-partner-info-modal-view.tsx | 41 ++++++++++++-- .../usePartnerInfoModal.tsx | 56 ++++++++++++------- 3 files changed, 77 insertions(+), 24 deletions(-) diff --git a/packages/mint-components/src/components/sqm-partner-info-modal/PartnerInfoModal.stories.tsx b/packages/mint-components/src/components/sqm-partner-info-modal/PartnerInfoModal.stories.tsx index 96c14a0c2..cc3c018c2 100644 --- a/packages/mint-components/src/components/sqm-partner-info-modal/PartnerInfoModal.stories.tsx +++ b/packages/mint-components/src/components/sqm-partner-info-modal/PartnerInfoModal.stories.tsx @@ -27,6 +27,8 @@ const demoCurrencies = [ ]; const noopCallbacks = { + onFirstNameChange: (e: any) => console.log("First name changed:", e), + onLastNameChange: (e: any) => console.log("Last name changed:", e), onCountryChange: (e: any) => console.log("Country changed:", e), onCurrencyChange: (e: any) => console.log("Currency changed:", e), onCheckboxChange: (e: any) => console.log("Checkbox changed:", e), @@ -66,6 +68,8 @@ const defaultProps: PartnerInfoModalViewProps = { loading: false, submitting: false, isExistingPartner: false, + firstName: "", + lastName: "", countryCode: "", currency: "", error: "", diff --git a/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx b/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx index ca6046dc9..c22ddc138 100644 --- a/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx +++ b/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx @@ -1,4 +1,4 @@ -import { h } from "@stencil/core"; +import { Fragment, h } from "@stencil/core"; import { createStyleSheet } from "../../styling/JSS"; import { intl } from "../../global/global"; @@ -8,6 +8,8 @@ export interface PartnerInfoModalViewProps { loading: boolean; submitting: boolean; isExistingPartner: boolean; + firstName: string; + lastName: string; countryCode: string; currency: string; error: string; @@ -18,6 +20,8 @@ export interface PartnerInfoModalViewProps { disabled: boolean; }; callbacks: { + onFirstNameChange: (e: any) => void; + onLastNameChange: (e: any) => void; onCountryChange: (e: any) => void; onCurrencyChange: (e: any) => void; onCheckboxChange: (e: any) => void; @@ -72,6 +76,13 @@ const style = { gap: "var(--sl-spacing-medium)", marginTop: "var(--sl-spacing-large)", }, + NameInput: { + "&::part(label)": { + fontWeight: "var(--sl-font-weight-normal)", + fontSize: + "var(--sl-input-label-font-size-medium)", + }, + }, ErrorMessage: { marginTop: "var(--sl-spacing-x-small)", }, @@ -132,7 +143,7 @@ export function PartnerInfoModalContentView(props: PartnerInfoModalViewProps) { {text.supportLink} ), - }, + } ); const description = states.isExistingPartner ? ( @@ -161,14 +172,36 @@ export function PartnerInfoModalContentView(props: PartnerInfoModalViewProps) { {text.termsAndConditionsLabel} ), - }, + } ); return (
- +
{description} + {(!states.firstName || !states.lastName) && ( + + + + + )} ( GET_FINANCE_NETWORK_SETTINGS, { variables: { filter: countryCode ? { countryCode_eq: countryCode } : {} }, - }, + } ); const [startImpactConnection, { loading: connectLoading }] = @@ -171,14 +173,14 @@ export function usePartnerInfoModal( (agg, settings) => { if (countryCode && settings.countryCode !== countryCode) return agg; const c = currenciesData?.currencies?.data?.find( - (cur) => cur.currencyCode === settings.currency, + (cur) => cur.currencyCode === settings.currency ); if (!c) return agg; if (agg.find((cur) => cur.currencyCode === settings.currency)) return agg; return [...agg, c]; }, - [], + [] ); return allValidCurrencies || []; }, [financeNetworkData, currenciesData, countryCode, isExistingPartner]); @@ -186,16 +188,16 @@ export function usePartnerInfoModal( const currencies = useMemo( () => [..._currencies].sort((a, b) => - a.displayName.localeCompare(b.displayName), + a.displayName.localeCompare(b.displayName) ), - [_currencies], + [_currencies] ); const [countrySearch, setCountrySearch] = useState(""); const [currencySearch, setCurrencySearch] = useState(""); const [filteredCountries, setFilteredCountries] = useState(countries || []); const [filteredCurrencies, setFilteredCurrencies] = useState( - currencies || [], + currencies || [] ); const [error, setError] = useState(""); @@ -215,8 +217,8 @@ export function usePartnerInfoModal( } else { setFilteredCountries( countries.filter((c) => - c.displayName.toLowerCase().includes(countrySearch.toLowerCase()), - ) || [], + c.displayName.toLowerCase().includes(countrySearch.toLowerCase()) + ) || [] ); } }, [countrySearch, countries]); @@ -228,14 +230,24 @@ export function usePartnerInfoModal( } else { setFilteredCurrencies( currencies.filter((c) => - c.currencyCode.toLowerCase().includes(currencySearch.toLowerCase()), - ) || [], + c.currencyCode.toLowerCase().includes(currencySearch.toLowerCase()) + ) || [] ); } }, [currencySearch, currencies]); const impactConnection = user?.impactConnection; + function onFirstNameChange(e: any) { + const value = e.target.value; + setFirstName(value); + } + + function onLastNameChange(e: any) { + const value = e.target.value; + setLastName(value); + } + function onCountryChange(e: any) { const value = e.detail?.item?.__value; if (!value) return; @@ -257,7 +269,7 @@ export function usePartnerInfoModal( } async function onSubmit() { - if (!allowBankingCollection || !countryCode || !currency) { + if (!allowBankingCollection || !countryCode || !currency || !firstName || !lastName) { setError(props.missingFieldsErrorText); return; } @@ -274,8 +286,8 @@ export function usePartnerInfoModal( id: user.id, accountId: user.accountId, }, - firstName: user.firstName, - lastName: user.lastName, + firstName, + lastName, countryCode, currency, }; @@ -297,7 +309,7 @@ export function usePartnerInfoModal( setError(validationMsg || props.networkErrorText); console.error( "Failed to create Impact connection:", - connectionResult?.validationErrors, + connectionResult?.validationErrors ); return; } @@ -324,6 +336,8 @@ export function usePartnerInfoModal( loading: userLoading || countriesLoading || currenciesLoading, submitting: connectLoading, isExistingPartner, + firstName, + lastName, countryCode, currency, error, @@ -334,6 +348,8 @@ export function usePartnerInfoModal( disabled: userLoading || connectLoading, }, callbacks: { + onFirstNameChange, + onLastNameChange, onCountryChange, onCurrencyChange, onCheckboxChange, From 2f8db38b2a36e934f7d75d66f02163fba6ef0d02 Mon Sep 17 00:00:00 2001 From: Ashley Osuna Date: Fri, 14 Aug 2026 12:04:08 -0700 Subject: [PATCH 02/20] updating specs, stories and pre-release version --- packages/mint-components/package.json | 2 +- .../PartnerInfoModal.stories.tsx | 24 +++++++++ .../sqm-partner-info-modal.feature | 54 ++++++++++++++++++- 3 files changed, 77 insertions(+), 3 deletions(-) diff --git a/packages/mint-components/package.json b/packages/mint-components/package.json index b98f14f1a..6783d0c68 100644 --- a/packages/mint-components/package.json +++ b/packages/mint-components/package.json @@ -1,7 +1,7 @@ { "name": "@saasquatch/mint-components", "title": "Mint Components", - "version": "2.3.1", + "version": "2.3.2-0", "description": "A minimal design library with components for referral and loyalty experiences. Built with Shoelace components by Saasquatch.", "icon": "https://res.cloudinary.com/saasquatch/image/upload/v1652219900/squatch-assets/For_Mint.svg", "raisins": "docs/raisins.json", diff --git a/packages/mint-components/src/components/sqm-partner-info-modal/PartnerInfoModal.stories.tsx b/packages/mint-components/src/components/sqm-partner-info-modal/PartnerInfoModal.stories.tsx index cc3c018c2..f56cb4cf7 100644 --- a/packages/mint-components/src/components/sqm-partner-info-modal/PartnerInfoModal.stories.tsx +++ b/packages/mint-components/src/components/sqm-partner-info-modal/PartnerInfoModal.stories.tsx @@ -212,3 +212,27 @@ export const SQMComponentNewPartner = () => { > ); }; + +export const PartnerHasFirstAndLastName = () => { + const props: PartnerInfoModalViewProps = { + ...defaultProps, + states: { + ...defaultProps.states, + firstName: "John", + lastName: "Doe", + }, + }; + return ; +}; + +export const PartnerHasFirstNameOnly = () => { + const props: PartnerInfoModalViewProps = { + ...defaultProps, + states: { + ...defaultProps.states, + firstName: "John", + lastName: "", + }, + }; + return ; +}; diff --git a/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal.feature b/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal.feature index 4ebc4d05a..587ff1a92 100644 --- a/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal.feature +++ b/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal.feature @@ -83,15 +83,47 @@ Feature: Partner Info Modal — country, currency, and T&C collection When the user checks the "Tax and banking" checkbox Then the primary button becomes enabled + @motivating + Scenario: User record has both firstName and lastName so the name inputs are hidden + Given the participant's user record has a non-empty `firstName` and `lastName` + When the partner-info modal opens + Then the "First name" input is not rendered + And the "Last name" input is not rendered + + @motivating + Scenario Outline: User record is missing firstName or lastName so both name inputs are shown + Given the participant's user record has firstName= and lastName= + When the partner-info modal opens + Then the "First name" input is rendered and enabled + And the "Last name" input is rendered and enabled + And the "First name" input is prefilled with + And the "Last name" input is prefilled with + + Examples: + | firstName | lastName | + | | Doe | + | Jane | | + | | | + + @motivating + Scenario: Name inputs are required to submit when they are shown + Given the partner-info modal is open with the "First name" and "Last name" inputs rendered + And the "Country", "Currency", and "Tax and banking" fields are all valid + When either the "First name" or "Last name" input is empty + Then the primary button is disabled + When both inputs have a non-empty value + Then the primary button becomes enabled + @minutia Scenario: Submit button is disabled Given the partner-info modal is open - When any one of (country, currency, allowBankingCollection) is missing + When any one of (country, currency, allowBankingCollection, firstName, lastName) is missing Then the submit button is disabled @motivating Scenario: Submitting the modal starts the Impact connection and closes the modal - Given the user has selected country "US", currency "USD", and checked the T&C checkbox + Given the participant's user record has a non-empty `firstName` and `lastName` + And the user has selected country "US", currency "USD", and checked the T&C checkbox When they click the primary button Then the modal calls the `startImpactConnection` mutation with | user.id | the participant id | @@ -103,6 +135,23 @@ Feature: Partner Info Modal — country, currency, and T&C collection And on success `impactConnection.connectionStatus` changes from "NOT_STARTED" to "STARTED" And the modal closes + @motivating + Scenario: Submitting the modal sends the entered firstName and lastName when the name inputs are shown + Given the participant's user record is missing `firstName` and/or `lastName` + And the "First name" input value is "Jane" + And the "Last name" input value is "Doe" + And the user has selected country "US", currency "USD", and checked the T&C checkbox + When they click the primary button + Then the modal calls the `startImpactConnection` mutation with + | user.id | the participant id | + | user.accountId | the participant accountId | + | firstName | "Jane" | + | lastName | "Doe" | + | countryCode | "US" | + | currency | "USD" | + And on success `impactConnection.connectionStatus` changes from "NOT_STARTED" to "STARTED" + And the modal closes + @motivating Scenario: Existing-partner submission attaches the participant to the linked publisher Given the participant is linked to an existing publisher with country "CA" and currency "CAD" @@ -130,6 +179,7 @@ Feature: Partner Info Modal — country, currency, and T&C collection Given the partner-info modal is open When the user clicks the primary button and the mutation is in flight Then the "Country", "Currency", and "Tax and banking" inputs are all disabled + And the "First name" and "Last name" inputs are disabled when they are rendered And the primary button shows a loading spinner @minutia From bae2e05d45dfa31958d34d048d2c94dee60eb2e5 Mon Sep 17 00:00:00 2001 From: Ashley Osuna Date: Fri, 14 Aug 2026 12:08:50 -0700 Subject: [PATCH 03/20] changeset --- packages/mint-components/.changeset/puny-brooms-call.md | 5 +++++ packages/mint-components/package.json | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 packages/mint-components/.changeset/puny-brooms-call.md diff --git a/packages/mint-components/.changeset/puny-brooms-call.md b/packages/mint-components/.changeset/puny-brooms-call.md new file mode 100644 index 000000000..663781c7d --- /dev/null +++ b/packages/mint-components/.changeset/puny-brooms-call.md @@ -0,0 +1,5 @@ +--- +"@saasquatch/mint-components": minor +--- + +Partner info modal now shows firstName and lastName inputs when either is missing from the user diff --git a/packages/mint-components/package.json b/packages/mint-components/package.json index 6783d0c68..44769d9e8 100644 --- a/packages/mint-components/package.json +++ b/packages/mint-components/package.json @@ -1,7 +1,7 @@ { "name": "@saasquatch/mint-components", "title": "Mint Components", - "version": "2.3.2-0", + "version": "2.3.1-2", "description": "A minimal design library with components for referral and loyalty experiences. Built with Shoelace components by Saasquatch.", "icon": "https://res.cloudinary.com/saasquatch/image/upload/v1652219900/squatch-assets/For_Mint.svg", "raisins": "docs/raisins.json", From ddc197e2ee31ae5e11051e2d7a48294546ace518 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Fri, 14 Aug 2026 19:11:05 +0000 Subject: [PATCH 04/20] publish: @saasquatch/mint-components v2.3.1-3 This commit was generated by GitHub Actions CI --- packages/mint-components/package-lock.json | 4 ++-- packages/mint-components/package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/mint-components/package-lock.json b/packages/mint-components/package-lock.json index 244148468..6e284ea77 100644 --- a/packages/mint-components/package-lock.json +++ b/packages/mint-components/package-lock.json @@ -1,12 +1,12 @@ { "name": "@saasquatch/mint-components", - "version": "2.3.1", + "version": "2.3.1-3", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@saasquatch/mint-components", - "version": "2.3.1", + "version": "2.3.1-3", "hasInstallScript": true, "license": "MIT", "dependencies": { diff --git a/packages/mint-components/package.json b/packages/mint-components/package.json index 44769d9e8..9efe36cbc 100644 --- a/packages/mint-components/package.json +++ b/packages/mint-components/package.json @@ -1,7 +1,7 @@ { "name": "@saasquatch/mint-components", "title": "Mint Components", - "version": "2.3.1-2", + "version": "2.3.1-3", "description": "A minimal design library with components for referral and loyalty experiences. Built with Shoelace components by Saasquatch.", "icon": "https://res.cloudinary.com/saasquatch/image/upload/v1652219900/squatch-assets/For_Mint.svg", "raisins": "docs/raisins.json", From be826e3171dec85b365ba31951033d32386c5c61 Mon Sep 17 00:00:00 2001 From: Ashley Osuna Date: Fri, 14 Aug 2026 12:33:13 -0700 Subject: [PATCH 05/20] fix: adding a shouldDisplayNameFields prop to prevent fields disappearing when typing --- .../PartnerInfoModal.stories.tsx | 2 ++ .../sqm-partner-info-modal-view.tsx | 3 ++- .../usePartnerInfoModal.tsx | 18 +++++++++++++++++- 3 files changed, 21 insertions(+), 2 deletions(-) diff --git a/packages/mint-components/src/components/sqm-partner-info-modal/PartnerInfoModal.stories.tsx b/packages/mint-components/src/components/sqm-partner-info-modal/PartnerInfoModal.stories.tsx index f56cb4cf7..db5035457 100644 --- a/packages/mint-components/src/components/sqm-partner-info-modal/PartnerInfoModal.stories.tsx +++ b/packages/mint-components/src/components/sqm-partner-info-modal/PartnerInfoModal.stories.tsx @@ -68,6 +68,7 @@ const defaultProps: PartnerInfoModalViewProps = { loading: false, submitting: false, isExistingPartner: false, + shouldDisplayNameFields: false, firstName: "", lastName: "", countryCode: "", @@ -232,6 +233,7 @@ export const PartnerHasFirstNameOnly = () => { ...defaultProps.states, firstName: "John", lastName: "", + shouldDisplayNameFields: true, }, }; return ; diff --git a/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx b/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx index c22ddc138..756221cd2 100644 --- a/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx +++ b/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx @@ -8,6 +8,7 @@ export interface PartnerInfoModalViewProps { loading: boolean; submitting: boolean; isExistingPartner: boolean; + shouldDisplayNameFields: boolean; firstName: string; lastName: string; countryCode: string; @@ -180,7 +181,7 @@ export function PartnerInfoModalContentView(props: PartnerInfoModalViewProps) {
{description} - {(!states.firstName || !states.lastName) && ( + {states.shouldDisplayNameFields && ( (null); + useEffect(() => { + if (shouldDisplayNameFields === null && user) { + setShouldDisplayNameFields(!user.firstName || !user.lastName); + } + }, [user, shouldDisplayNameFields]); + const [firstName, setFirstName] = useState(user?.firstName || ""); const [lastName, setLastName] = useState(user?.lastName || ""); @@ -269,7 +278,13 @@ export function usePartnerInfoModal( } async function onSubmit() { - if (!allowBankingCollection || !countryCode || !currency || !firstName || !lastName) { + if ( + !allowBankingCollection || + !countryCode || + !currency || + !firstName || + !lastName + ) { setError(props.missingFieldsErrorText); return; } @@ -335,6 +350,7 @@ export function usePartnerInfoModal( open: showModal, loading: userLoading || countriesLoading || currenciesLoading, submitting: connectLoading, + shouldDisplayNameFields, isExistingPartner, firstName, lastName, From 66354b63b9eba81fc712a6600a4b82fff6439cd7 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Fri, 14 Aug 2026 19:35:39 +0000 Subject: [PATCH 06/20] publish: @saasquatch/mint-components v2.3.1-4 This commit was generated by GitHub Actions CI --- packages/mint-components/package-lock.json | 4 ++-- packages/mint-components/package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/mint-components/package-lock.json b/packages/mint-components/package-lock.json index 6e284ea77..c143a6581 100644 --- a/packages/mint-components/package-lock.json +++ b/packages/mint-components/package-lock.json @@ -1,12 +1,12 @@ { "name": "@saasquatch/mint-components", - "version": "2.3.1-3", + "version": "2.3.1-4", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@saasquatch/mint-components", - "version": "2.3.1-3", + "version": "2.3.1-4", "hasInstallScript": true, "license": "MIT", "dependencies": { diff --git a/packages/mint-components/package.json b/packages/mint-components/package.json index 9efe36cbc..9b02b4583 100644 --- a/packages/mint-components/package.json +++ b/packages/mint-components/package.json @@ -1,7 +1,7 @@ { "name": "@saasquatch/mint-components", "title": "Mint Components", - "version": "2.3.1-3", + "version": "2.3.1-4", "description": "A minimal design library with components for referral and loyalty experiences. Built with Shoelace components by Saasquatch.", "icon": "https://res.cloudinary.com/saasquatch/image/upload/v1652219900/squatch-assets/For_Mint.svg", "raisins": "docs/raisins.json", From 8aa47279d2ac2ad54295f70e8030f6c6e7cbf9bb Mon Sep 17 00:00:00 2001 From: Ashley Osuna Date: Fri, 14 Aug 2026 12:42:35 -0700 Subject: [PATCH 07/20] disabling submit button when firstName/lastName are missing --- .../sqm-partner-info-modal/sqm-partner-info-modal-view.tsx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx b/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx index 756221cd2..43c3bccf1 100644 --- a/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx +++ b/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx @@ -288,7 +288,9 @@ export function PartnerInfoModalContentView(props: PartnerInfoModalViewProps) { states.submitting || !states.countryCode || !states.currency || - !states.allowBankingCollection + !states.allowBankingCollection || + !states.firstName || + !states.lastName } onClick={callbacks.onSubmit} class={sheet.classes.SubmitButton} From c3c3bc2735a420885d3056199f72c2b456f47770 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Fri, 14 Aug 2026 19:45:03 +0000 Subject: [PATCH 08/20] publish: @saasquatch/mint-components v2.3.1-5 This commit was generated by GitHub Actions CI --- packages/mint-components/package-lock.json | 4 ++-- packages/mint-components/package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/mint-components/package-lock.json b/packages/mint-components/package-lock.json index c143a6581..6601b6fa2 100644 --- a/packages/mint-components/package-lock.json +++ b/packages/mint-components/package-lock.json @@ -1,12 +1,12 @@ { "name": "@saasquatch/mint-components", - "version": "2.3.1-4", + "version": "2.3.1-5", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@saasquatch/mint-components", - "version": "2.3.1-4", + "version": "2.3.1-5", "hasInstallScript": true, "license": "MIT", "dependencies": { diff --git a/packages/mint-components/package.json b/packages/mint-components/package.json index 9b02b4583..069eca128 100644 --- a/packages/mint-components/package.json +++ b/packages/mint-components/package.json @@ -1,7 +1,7 @@ { "name": "@saasquatch/mint-components", "title": "Mint Components", - "version": "2.3.1-4", + "version": "2.3.1-5", "description": "A minimal design library with components for referral and loyalty experiences. Built with Shoelace components by Saasquatch.", "icon": "https://res.cloudinary.com/saasquatch/image/upload/v1652219900/squatch-assets/For_Mint.svg", "raisins": "docs/raisins.json", From 6743e2722bdecc1694193da12318d8cf1559ec77 Mon Sep 17 00:00:00 2001 From: Ashley Osuna Date: Fri, 14 Aug 2026 13:02:11 -0700 Subject: [PATCH 09/20] fix: onSubmit button guard, setting firstName, lastName when user is populated --- .../sqm-partner-info-modal-view.tsx | 7 +++---- .../usePartnerInfoModal.tsx | 17 +++++++++++------ 2 files changed, 14 insertions(+), 10 deletions(-) diff --git a/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx b/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx index 43c3bccf1..c3a883a26 100644 --- a/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx +++ b/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx @@ -80,8 +80,7 @@ const style = { NameInput: { "&::part(label)": { fontWeight: "var(--sl-font-weight-normal)", - fontSize: - "var(--sl-input-label-font-size-medium)", + fontSize: "var(--sl-input-label-font-size-medium)", }, }, ErrorMessage: { @@ -289,8 +288,8 @@ export function PartnerInfoModalContentView(props: PartnerInfoModalViewProps) { !states.countryCode || !states.currency || !states.allowBankingCollection || - !states.firstName || - !states.lastName + (states.shouldDisplayNameFields && + (!states.firstName || !states.lastName)) } onClick={callbacks.onSubmit} class={sheet.classes.SubmitButton} diff --git a/packages/mint-components/src/components/sqm-partner-info-modal/usePartnerInfoModal.tsx b/packages/mint-components/src/components/sqm-partner-info-modal/usePartnerInfoModal.tsx index 4ffa4c79c..322ed1660 100644 --- a/packages/mint-components/src/components/sqm-partner-info-modal/usePartnerInfoModal.tsx +++ b/packages/mint-components/src/components/sqm-partner-info-modal/usePartnerInfoModal.tsx @@ -212,12 +212,18 @@ export function usePartnerInfoModal( const [error, setError] = useState(""); const [success, setSuccess] = useState(false); + const [initialized, setInitialized] = useState(false); useEffect(() => { + if (initialized || !userData) return; + setFirstName(user?.firstName || ""); + setLastName(user?.lastName || ""); const publisher = user?.impactConnection?.publisher; - if (!userData || !publisher) return; - setCountryCode(publisher.countryCode); - setCurrency(publisher.currency); - }, [userData, user]); + if (publisher) { + setCountryCode(publisher.countryCode); + setCurrency(publisher.currency); + } + setInitialized(true); + }, [userData, user, initialized]); useEffect(() => { if (!countries?.length) return; @@ -282,8 +288,7 @@ export function usePartnerInfoModal( !allowBankingCollection || !countryCode || !currency || - !firstName || - !lastName + (shouldDisplayNameFields && (!firstName || !lastName)) ) { setError(props.missingFieldsErrorText); return; From 4a86fe8553a7f60488ec90ca08029a5fe7312253 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Fri, 14 Aug 2026 20:06:42 +0000 Subject: [PATCH 10/20] publish: @saasquatch/mint-components v2.3.1-6 This commit was generated by GitHub Actions CI --- packages/mint-components/package-lock.json | 4 ++-- packages/mint-components/package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/mint-components/package-lock.json b/packages/mint-components/package-lock.json index 6601b6fa2..336cdf641 100644 --- a/packages/mint-components/package-lock.json +++ b/packages/mint-components/package-lock.json @@ -1,12 +1,12 @@ { "name": "@saasquatch/mint-components", - "version": "2.3.1-5", + "version": "2.3.1-6", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@saasquatch/mint-components", - "version": "2.3.1-5", + "version": "2.3.1-6", "hasInstallScript": true, "license": "MIT", "dependencies": { diff --git a/packages/mint-components/package.json b/packages/mint-components/package.json index 069eca128..239483c3c 100644 --- a/packages/mint-components/package.json +++ b/packages/mint-components/package.json @@ -1,7 +1,7 @@ { "name": "@saasquatch/mint-components", "title": "Mint Components", - "version": "2.3.1-5", + "version": "2.3.1-6", "description": "A minimal design library with components for referral and loyalty experiences. Built with Shoelace components by Saasquatch.", "icon": "https://res.cloudinary.com/saasquatch/image/upload/v1652219900/squatch-assets/For_Mint.svg", "raisins": "docs/raisins.json", From 5d4fcae3c1f691a8eb6151641d8df1e8df041b75 Mon Sep 17 00:00:00 2001 From: Andy Date: Fri, 14 Aug 2026 13:53:43 -0700 Subject: [PATCH 11/20] Add loading spinner --- .../PartnerInfoModal.stories.tsx | 11 +++++ .../sqm-partner-info-modal/readme.md | 44 +++++++++---------- .../sqm-partner-info-modal-view.tsx | 26 +++++++++++ 3 files changed, 59 insertions(+), 22 deletions(-) diff --git a/packages/mint-components/src/components/sqm-partner-info-modal/PartnerInfoModal.stories.tsx b/packages/mint-components/src/components/sqm-partner-info-modal/PartnerInfoModal.stories.tsx index db5035457..de13fbd03 100644 --- a/packages/mint-components/src/components/sqm-partner-info-modal/PartnerInfoModal.stories.tsx +++ b/packages/mint-components/src/components/sqm-partner-info-modal/PartnerInfoModal.stories.tsx @@ -238,3 +238,14 @@ export const PartnerHasFirstNameOnly = () => { }; return ; }; + +export const Loading = () => { + const props: PartnerInfoModalViewProps = { + ...defaultProps, + states: { + ...defaultProps.states, + loading: true, + }, + }; + return ; +}; diff --git a/packages/mint-components/src/components/sqm-partner-info-modal/readme.md b/packages/mint-components/src/components/sqm-partner-info-modal/readme.md index 100a57fff..1b1dc1617 100644 --- a/packages/mint-components/src/components/sqm-partner-info-modal/readme.md +++ b/packages/mint-components/src/components/sqm-partner-info-modal/readme.md @@ -7,28 +7,28 @@ ## Properties -| Property | Attribute | Description | Type | Default | -| ----------------------------------- | -------------------------------------- | ----------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `allowBankingCollection` | `allow-banking-collection` | Edit the property called terms and conditions text to change what's displayed for {termsAndConditionsLink}. | `string` | `"I have read the {termsAndConditionsLink} and allow impact.com to collect my tax and banking information."` | -| `confirmButtonLabel` | `confirm-button-label` | | `string` | `"Confirm"` | -| `countryLabel` | `country-label` | | `string` | `"Country"` | -| `currencyLabel` | `currency-label` | | `string` | `"Currency"` | -| `demoData` | -- | | `{ states?: { open: boolean; loading: boolean; submitting: boolean; isExistingPartner: boolean; countryCode: string; currency: string; error: string; success: boolean; filteredCountries: { countryCode: string; displayName: string; }[]; filteredCurrencies: { currencyCode: string; displayName: string; }[]; allowBankingCollection: boolean; disabled: boolean; }; }` | `undefined` | -| `descriptionExistingPartner` | `description-existing-partner` | Description for existing partner confirmation | `string` | `"We found an account with this email on our referral program provider, impact.com. Please confirm your country and currency now to get your future rewards faster."` | -| `descriptionNewPartner` | `description-new-partner` | Description for new partner setup | `string` | `"Confirm your country and currency now to get your future rewards faster."` | -| `inModal` | `in-modal` | Used to render in another modal. | `boolean` | `false` | -| `missingFieldsErrorText` | `missing-fields-error-text` | | `string` | `"Please fill out all fields."` | -| `modalHeader` | `modal-header` | Header text when user has no existing partner | `string` | `"Let's get you ready for rewards"` | -| `modalHeaderExistingPartner` | `modal-header-existing-partner` | Header text when user has an existing partner | `string` | `"We found an existing account"` | -| `networkErrorText` | `network-error-text` | | `string` | `"An error occurred. Please try again."` | -| `searchCountryPlaceholder` | `search-country-placeholder` | | `string` | `"Search for a country"` | -| `searchCurrencyPlaceholder` | `search-currency-placeholder` | | `string` | `"Search for a currency"` | -| `stateController` | `state-controller` | | `string` | `'{"sqm-partner-info-modal":{"states":{"open":false}}}'` | -| `submitButtonLabel` | `submit-button-label` | | `string` | `"Submit"` | -| `supportDescriptionExistingPartner` | `support-description-existing-partner` | Support description for existing partner confirmation | `string` | `"If this is a mistake, please contact {supportLink} or sign up for this referral program with a different email."` | -| `supportLink` | `support-link` | Support description for existing partner confirmation | `string` | `"Support"` | -| `termsAndConditionsLabel` | `terms-and-conditions-label` | The link text that appears in the terms and conditions checkbox | `string` | `"terms and conditions"` | -| `termsAndConditionsLink` | `terms-and-conditions-link` | The link that appears in the terms and conditions checkbox | `string` | `"https://terms.advocate.impact.com/PayoutTermsAndConditions.html"` | +| Property | Attribute | Description | Type | Default | +| ----------------------------------- | -------------------------------------- | ----------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `allowBankingCollection` | `allow-banking-collection` | Edit the property called terms and conditions text to change what's displayed for {termsAndConditionsLink}. | `string` | `"I have read the {termsAndConditionsLink} and allow impact.com to collect my tax and banking information."` | +| `confirmButtonLabel` | `confirm-button-label` | | `string` | `"Confirm"` | +| `countryLabel` | `country-label` | | `string` | `"Country"` | +| `currencyLabel` | `currency-label` | | `string` | `"Currency"` | +| `demoData` | -- | | `{ states?: { open: boolean; loading: boolean; submitting: boolean; isExistingPartner: boolean; shouldDisplayNameFields: boolean; firstName: string; lastName: string; countryCode: string; currency: string; error: string; success: boolean; filteredCountries: { countryCode: string; displayName: string; }[]; filteredCurrencies: { currencyCode: string; displayName: string; }[]; allowBankingCollection: boolean; disabled: boolean; }; }` | `undefined` | +| `descriptionExistingPartner` | `description-existing-partner` | Description for existing partner confirmation | `string` | `"We found an account with this email on our referral program provider, impact.com. Please confirm your country and currency now to get your future rewards faster."` | +| `descriptionNewPartner` | `description-new-partner` | Description for new partner setup | `string` | `"Confirm your country and currency now to get your future rewards faster."` | +| `inModal` | `in-modal` | Used to render in another modal. | `boolean` | `false` | +| `missingFieldsErrorText` | `missing-fields-error-text` | | `string` | `"Please fill out all fields."` | +| `modalHeader` | `modal-header` | Header text when user has no existing partner | `string` | `"Let's get you ready for rewards"` | +| `modalHeaderExistingPartner` | `modal-header-existing-partner` | Header text when user has an existing partner | `string` | `"We found an existing account"` | +| `networkErrorText` | `network-error-text` | | `string` | `"An error occurred. Please try again."` | +| `searchCountryPlaceholder` | `search-country-placeholder` | | `string` | `"Search for a country"` | +| `searchCurrencyPlaceholder` | `search-currency-placeholder` | | `string` | `"Search for a currency"` | +| `stateController` | `state-controller` | | `string` | `'{"sqm-partner-info-modal":{"states":{"open":false}}}'` | +| `submitButtonLabel` | `submit-button-label` | | `string` | `"Submit"` | +| `supportDescriptionExistingPartner` | `support-description-existing-partner` | Support description for existing partner confirmation | `string` | `"If this is a mistake, please contact {supportLink} or sign up for this referral program with a different email."` | +| `supportLink` | `support-link` | Support description for existing partner confirmation | `string` | `"Support"` | +| `termsAndConditionsLabel` | `terms-and-conditions-label` | The link text that appears in the terms and conditions checkbox | `string` | `"terms and conditions"` | +| `termsAndConditionsLink` | `terms-and-conditions-link` | The link that appears in the terms and conditions checkbox | `string` | `"https://terms.advocate.impact.com/PayoutTermsAndConditions.html"` | ## Dependencies diff --git a/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx b/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx index c3a883a26..1b9d5c67a 100644 --- a/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx +++ b/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx @@ -175,6 +175,12 @@ export function PartnerInfoModalContentView(props: PartnerInfoModalViewProps) { } ); + if (states.loading) { + return ( + + ); + } + return (
@@ -202,6 +208,26 @@ export function PartnerInfoModalContentView(props: PartnerInfoModalViewProps) { /> )} + + + + Date: Fri, 14 Aug 2026 20:55:54 +0000 Subject: [PATCH 12/20] publish: @saasquatch/mint-components v2.3.1-7 This commit was generated by GitHub Actions CI --- packages/mint-components/package-lock.json | 4 ++-- packages/mint-components/package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/mint-components/package-lock.json b/packages/mint-components/package-lock.json index 336cdf641..cab9c3373 100644 --- a/packages/mint-components/package-lock.json +++ b/packages/mint-components/package-lock.json @@ -1,12 +1,12 @@ { "name": "@saasquatch/mint-components", - "version": "2.3.1-6", + "version": "2.3.1-7", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@saasquatch/mint-components", - "version": "2.3.1-6", + "version": "2.3.1-7", "hasInstallScript": true, "license": "MIT", "dependencies": { diff --git a/packages/mint-components/package.json b/packages/mint-components/package.json index 239483c3c..9e9eadde5 100644 --- a/packages/mint-components/package.json +++ b/packages/mint-components/package.json @@ -1,7 +1,7 @@ { "name": "@saasquatch/mint-components", "title": "Mint Components", - "version": "2.3.1-6", + "version": "2.3.1-7", "description": "A minimal design library with components for referral and loyalty experiences. Built with Shoelace components by Saasquatch.", "icon": "https://res.cloudinary.com/saasquatch/image/upload/v1652219900/squatch-assets/For_Mint.svg", "raisins": "docs/raisins.json", From d6c219077dba15b8dc1259f5249b0b152dbeafe0 Mon Sep 17 00:00:00 2001 From: Ashley Osuna Date: Fri, 14 Aug 2026 14:04:57 -0700 Subject: [PATCH 13/20] cleanup --- .../sqm-partner-info-modal-view.tsx | 20 ------------------- .../usePartnerInfoModal.tsx | 19 ++++++------------ 2 files changed, 6 insertions(+), 33 deletions(-) diff --git a/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx b/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx index 1b9d5c67a..7132372f2 100644 --- a/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx +++ b/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx @@ -208,26 +208,6 @@ export function PartnerInfoModalContentView(props: PartnerInfoModalViewProps) { /> )} - - - - (null); - useEffect(() => { - if (shouldDisplayNameFields === null && user) { - setShouldDisplayNameFields(!user.firstName || !user.lastName); - } - }, [user, shouldDisplayNameFields]); - const [firstName, setFirstName] = useState(user?.firstName || ""); const [lastName, setLastName] = useState(user?.lastName || ""); @@ -212,18 +206,17 @@ export function usePartnerInfoModal( const [error, setError] = useState(""); const [success, setSuccess] = useState(false); - const [initialized, setInitialized] = useState(false); useEffect(() => { - if (initialized || !userData) return; - setFirstName(user?.firstName || ""); - setLastName(user?.lastName || ""); - const publisher = user?.impactConnection?.publisher; + if (shouldDisplayNameFields !== null || !user) return; + setShouldDisplayNameFields(!user.firstName || !user.lastName); + setFirstName(user.firstName || ""); + setLastName(user.lastName || ""); + const publisher = user.impactConnection?.publisher; if (publisher) { setCountryCode(publisher.countryCode); setCurrency(publisher.currency); } - setInitialized(true); - }, [userData, user, initialized]); + }, [user, shouldDisplayNameFields]); useEffect(() => { if (!countries?.length) return; From 86c7d94cac8cff91020279b1922a4f59c61b9a4d Mon Sep 17 00:00:00 2001 From: Andy Date: Fri, 14 Aug 2026 14:05:08 -0700 Subject: [PATCH 14/20] Fix spinner placement --- .../sqm-partner-info-modal-view.tsx | 32 +++---------------- 1 file changed, 5 insertions(+), 27 deletions(-) diff --git a/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx b/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx index 1b9d5c67a..602bb33b5 100644 --- a/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx +++ b/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx @@ -175,12 +175,6 @@ export function PartnerInfoModalContentView(props: PartnerInfoModalViewProps) { } ); - if (states.loading) { - return ( - - ); - } - return (
@@ -208,26 +202,6 @@ export function PartnerInfoModalContentView(props: PartnerInfoModalViewProps) { /> )} - - - -

{modalHeader}

- + {states.loading ? ( + + ) : ( + + )}
); From 4be38b05c88f579a9cd077a0398641456e00ffba Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Fri, 14 Aug 2026 21:07:55 +0000 Subject: [PATCH 15/20] publish: @saasquatch/mint-components v2.3.1-8 This commit was generated by GitHub Actions CI --- packages/mint-components/package-lock.json | 4 ++-- packages/mint-components/package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/mint-components/package-lock.json b/packages/mint-components/package-lock.json index cab9c3373..bb9138cb4 100644 --- a/packages/mint-components/package-lock.json +++ b/packages/mint-components/package-lock.json @@ -1,12 +1,12 @@ { "name": "@saasquatch/mint-components", - "version": "2.3.1-7", + "version": "2.3.1-8", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@saasquatch/mint-components", - "version": "2.3.1-7", + "version": "2.3.1-8", "hasInstallScript": true, "license": "MIT", "dependencies": { diff --git a/packages/mint-components/package.json b/packages/mint-components/package.json index 9e9eadde5..17d6a56b0 100644 --- a/packages/mint-components/package.json +++ b/packages/mint-components/package.json @@ -1,7 +1,7 @@ { "name": "@saasquatch/mint-components", "title": "Mint Components", - "version": "2.3.1-7", + "version": "2.3.1-8", "description": "A minimal design library with components for referral and loyalty experiences. Built with Shoelace components by Saasquatch.", "icon": "https://res.cloudinary.com/saasquatch/image/upload/v1652219900/squatch-assets/For_Mint.svg", "raisins": "docs/raisins.json", From 4cafc88bc922795e2175da6a166e238566df485d Mon Sep 17 00:00:00 2001 From: Andy Date: Fri, 14 Aug 2026 14:19:19 -0700 Subject: [PATCH 16/20] Remove loading state, add check to showModal instead --- .../sqm-partner-info-modal/sqm-partner-info-modal-view.tsx | 6 +----- .../sqm-partner-info-modal/usePartnerInfoModal.tsx | 1 + 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx b/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx index 602bb33b5..c3a883a26 100644 --- a/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx +++ b/packages/mint-components/src/components/sqm-partner-info-modal/sqm-partner-info-modal-view.tsx @@ -331,11 +331,7 @@ export function PartnerInfoModalView(props: PartnerInfoModalViewProps) { onSl-initial-focus={callbacks.onInitialFocus} >

{modalHeader}

- {states.loading ? ( - - ) : ( - - )} +
); diff --git a/packages/mint-components/src/components/sqm-partner-info-modal/usePartnerInfoModal.tsx b/packages/mint-components/src/components/sqm-partner-info-modal/usePartnerInfoModal.tsx index 96dbc138c..33ad52489 100644 --- a/packages/mint-components/src/components/sqm-partner-info-modal/usePartnerInfoModal.tsx +++ b/packages/mint-components/src/components/sqm-partner-info-modal/usePartnerInfoModal.tsx @@ -341,6 +341,7 @@ export function usePartnerInfoModal( const showModal = !success && !userLoading && + shouldDisplayNameFields !== null && impactConnection?.connectionStatus === "NOT_STARTED"; return { From aea810c14d5fa0b92f6cf44afadd18c62aeba478 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Fri, 14 Aug 2026 21:22:30 +0000 Subject: [PATCH 17/20] publish: @saasquatch/mint-components v2.3.1-9 This commit was generated by GitHub Actions CI --- packages/mint-components/package-lock.json | 4 ++-- packages/mint-components/package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/mint-components/package-lock.json b/packages/mint-components/package-lock.json index bb9138cb4..7d6c36b33 100644 --- a/packages/mint-components/package-lock.json +++ b/packages/mint-components/package-lock.json @@ -1,12 +1,12 @@ { "name": "@saasquatch/mint-components", - "version": "2.3.1-8", + "version": "2.3.1-9", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@saasquatch/mint-components", - "version": "2.3.1-8", + "version": "2.3.1-9", "hasInstallScript": true, "license": "MIT", "dependencies": { diff --git a/packages/mint-components/package.json b/packages/mint-components/package.json index 17d6a56b0..e9cd822a6 100644 --- a/packages/mint-components/package.json +++ b/packages/mint-components/package.json @@ -1,7 +1,7 @@ { "name": "@saasquatch/mint-components", "title": "Mint Components", - "version": "2.3.1-8", + "version": "2.3.1-9", "description": "A minimal design library with components for referral and loyalty experiences. Built with Shoelace components by Saasquatch.", "icon": "https://res.cloudinary.com/saasquatch/image/upload/v1652219900/squatch-assets/For_Mint.svg", "raisins": "docs/raisins.json", From 66d26a4415e20f1def4dfd632c08196f0bb12e97 Mon Sep 17 00:00:00 2001 From: Ashley Osuna Date: Fri, 14 Aug 2026 15:10:14 -0700 Subject: [PATCH 18/20] fix: address review comments --- packages/mint-components/package.json | 2 +- .../sqm-partner-info-modal/usePartnerInfoModal.tsx | 9 +++++---- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/packages/mint-components/package.json b/packages/mint-components/package.json index e9cd822a6..b98f14f1a 100644 --- a/packages/mint-components/package.json +++ b/packages/mint-components/package.json @@ -1,7 +1,7 @@ { "name": "@saasquatch/mint-components", "title": "Mint Components", - "version": "2.3.1-9", + "version": "2.3.1", "description": "A minimal design library with components for referral and loyalty experiences. Built with Shoelace components by Saasquatch.", "icon": "https://res.cloudinary.com/saasquatch/image/upload/v1652219900/squatch-assets/For_Mint.svg", "raisins": "docs/raisins.json", diff --git a/packages/mint-components/src/components/sqm-partner-info-modal/usePartnerInfoModal.tsx b/packages/mint-components/src/components/sqm-partner-info-modal/usePartnerInfoModal.tsx index 33ad52489..9f852f1b3 100644 --- a/packages/mint-components/src/components/sqm-partner-info-modal/usePartnerInfoModal.tsx +++ b/packages/mint-components/src/components/sqm-partner-info-modal/usePartnerInfoModal.tsx @@ -205,9 +205,10 @@ export function usePartnerInfoModal( const [error, setError] = useState(""); const [success, setSuccess] = useState(false); - + const [initialized, setInitialized] = useState(false); + useEffect(() => { - if (shouldDisplayNameFields !== null || !user) return; + if (initialized || !user) return; setShouldDisplayNameFields(!user.firstName || !user.lastName); setFirstName(user.firstName || ""); setLastName(user.lastName || ""); @@ -216,7 +217,8 @@ export function usePartnerInfoModal( setCountryCode(publisher.countryCode); setCurrency(publisher.currency); } - }, [user, shouldDisplayNameFields]); + setInitialized(true); + }, [user, initialized]); useEffect(() => { if (!countries?.length) return; @@ -341,7 +343,6 @@ export function usePartnerInfoModal( const showModal = !success && !userLoading && - shouldDisplayNameFields !== null && impactConnection?.connectionStatus === "NOT_STARTED"; return { From a85c7777ad7c8d5a7a8be4e4b07061b49bebe592 Mon Sep 17 00:00:00 2001 From: Ashley Osuna Date: Fri, 14 Aug 2026 15:17:27 -0700 Subject: [PATCH 19/20] Potential fix for pull request finding Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> --- .../sqm-partner-info-modal/usePartnerInfoModal.tsx | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/packages/mint-components/src/components/sqm-partner-info-modal/usePartnerInfoModal.tsx b/packages/mint-components/src/components/sqm-partner-info-modal/usePartnerInfoModal.tsx index 9f852f1b3..7132d4f6a 100644 --- a/packages/mint-components/src/components/sqm-partner-info-modal/usePartnerInfoModal.tsx +++ b/packages/mint-components/src/components/sqm-partner-info-modal/usePartnerInfoModal.tsx @@ -126,11 +126,9 @@ export function usePartnerInfoModal( {} ); - const [shouldDisplayNameFields, setShouldDisplayNameFields] = useState< - boolean | null - >(null); - const [firstName, setFirstName] = useState(user?.firstName || ""); - const [lastName, setLastName] = useState(user?.lastName || ""); + const [shouldDisplayNameFields, setShouldDisplayNameFields] = useState(false); + const [firstName, setFirstName] = useState(user?.firstName ?? ""); + const [lastName, setLastName] = useState(user?.lastName ?? ""); // No pre-filled country, use locale to determine countryCode instead const [countryCode, setCountryCode] = useState( From 0f524df5c09866596033babca31d599ca830ca73 Mon Sep 17 00:00:00 2001 From: Ashley Osuna Date: Fri, 14 Aug 2026 15:25:57 -0700 Subject: [PATCH 20/20] reverting package-lock --- packages/mint-components/package-lock.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/mint-components/package-lock.json b/packages/mint-components/package-lock.json index 7d6c36b33..244148468 100644 --- a/packages/mint-components/package-lock.json +++ b/packages/mint-components/package-lock.json @@ -1,12 +1,12 @@ { "name": "@saasquatch/mint-components", - "version": "2.3.1-9", + "version": "2.3.1", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@saasquatch/mint-components", - "version": "2.3.1-9", + "version": "2.3.1", "hasInstallScript": true, "license": "MIT", "dependencies": {