Skip to content

Commit f27327f

Browse files
authored
Merge branch 'main' into feat/toggle-upsells
2 parents c9301d1 + 09e7a27 commit f27327f

24 files changed

+68
-49
lines changed

.github/workflows/tests.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@ name: Tests
22

33
on:
44
push:
5+
branches:
6+
- '**'
7+
tags-ignore:
8+
- 'production-*'
59

610
concurrency:
711
group: ${{ github.workflow }}-${{ github.ref }}

app/javascript/components/Download/OpenInAppButton.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ type Props = { iosAppUrl: string; androidAppUrl: string };
77
export const OpenInAppButton = ({ iosAppUrl, androidAppUrl }: Props) => (
88
<Popover trigger={<span className="button">Open in app</span>}>
99
<div
10+
className="mx-auto"
1011
style={{
1112
display: "grid",
1213
textAlign: "center",

app/javascript/components/Post/PostCommentsSection.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,7 @@ export const PostCommentsSection = ({ paginated_comments }: Props) => {
113113
});
114114
showAlert("Successfully posted your comment", "success");
115115
upsertComment(comment);
116+
setDraft(null);
116117
} catch (e) {
117118
assertResponseError(e);
118119
showAlert(`An error occurred while posting your comment - ${e.message}`, "error");

app/javascript/components/Settings/PaymentsPage/BankAccountSection.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -939,7 +939,7 @@ const BankAccountSection = ({
939939
</fieldset>
940940
<div style={{ display: "grid", gap: "var(--spacer-2)" }}>
941941
{showNewBankAccount ? (
942-
<div style={{ display: "grid", gap: "var(--spacer-5)", gridAutoFlow: "column", gridAutoColumns: "1fr" }}>
942+
<div className="grid gap-5 md:auto-cols-fr md:grid-flow-col">
943943
{user.country_code === "CA" ? (
944944
<>
945945
<fieldset className={cx({ danger: errorFieldNames.has("transit_number") })}>

app/javascript/components/server-components/AffiliatedPage.tsx

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -287,21 +287,21 @@ const AffiliatedPage = ({
287287
selectedTab="affiliated"
288288
title={isShowingGlobalAffiliates ? "Gumroad Affiliates" : undefined}
289289
ctaButton={
290-
<>
291-
<Search onSearch={handleSearch} value={state.query} />
292-
{isShowingGlobalAffiliates ? (
293-
<Button onClick={() => toggleOpen(false)}>
294-
<Icon name="x-circle" />
295-
Close
296-
</Button>
297-
) : (
290+
isShowingGlobalAffiliates ? (
291+
<Button onClick={() => toggleOpen(false)}>
292+
<Icon name="x-circle" />
293+
Close
294+
</Button>
295+
) : (
296+
<>
297+
{initialAffiliatedProducts.length > 0 && <Search onSearch={handleSearch} value={state.query} />}
298298
<WithTooltip position="bottom" tip={affiliatesDisabledReason}>
299299
<Button color="accent" disabled={affiliatesDisabledReason !== null} onClick={() => toggleOpen(true)}>
300300
Gumroad affiliate
301301
</Button>
302302
</WithTooltip>
303-
)}
304-
</>
303+
</>
304+
)
305305
}
306306
archivedTabVisible={archivedTabVisible}
307307
>

app/javascript/components/server-components/CommunitiesPage/ChatMessageList.tsx

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,8 @@ export const ChatMessageList = ({
2828
const dateObserversRef = React.useRef<Map<string, IntersectionObserver>>(new Map());
2929
const dateElementsRef = React.useRef<Map<string, HTMLDivElement>>(new Map());
3030

31+
const isSafari = typeof window !== "undefined" && /^((?!chrome|android).)*safari/iu.test(navigator.userAgent);
32+
3133
const lastReadMessageCreatedAt = community.last_read_community_chat_message_created_at;
3234
let lastReadMessageIndex = -1;
3335
if (lastReadMessageCreatedAt) {
@@ -97,6 +99,11 @@ export const ChatMessageList = ({
9799
// Observer for the date group content visibility
98100
const groupObserver = new IntersectionObserver(([entry]) => {
99101
setVisibleDateGroups((prev) => {
102+
// Safari has issues with rapid IntersectionObserver callbacks,
103+
// causing the UI to jump around when scrolling.
104+
// So we skip updating the visible date groups in Safari.
105+
if (isSafari) return prev;
106+
100107
if (entry?.isIntersecting && !prev.includes(date)) {
101108
return [...prev, date].sort();
102109
} else if (!entry?.isIntersecting && prev.includes(date)) {

app/javascript/components/server-components/DownloadPage/WithContent.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -341,7 +341,7 @@ const WithContent = ({
341341
{isDesktop ? null : (
342342
<Popover
343343
aria-label="Table of Contents"
344-
position="top"
344+
position="bottom"
345345
trigger={
346346
<div className="button">
347347
<Icon name="unordered-list" />

app/javascript/components/server-components/FollowersPage.tsx

Lines changed: 23 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -120,27 +120,29 @@ export const FollowersPage = ({ followers: initialFollowers, per_page, total }:
120120
title="Subscribers"
121121
actions={
122122
<>
123-
<Popover
124-
open={searchBoxOpen}
125-
onToggle={setSearchBoxOpen}
126-
aria-label="Search"
127-
trigger={
128-
<WithTooltip tip="Search" position="bottom">
129-
<div className="button">
130-
<Icon name="solid-search" />
131-
</div>
132-
</WithTooltip>
133-
}
134-
>
135-
<input
136-
ref={searchInputRef}
137-
value={searchQuery}
138-
autoFocus
139-
type="text"
140-
placeholder="Search followers"
141-
onChange={(evt) => setSearchQuery(evt.target.value)}
142-
/>
143-
</Popover>
123+
{(followers.length > 0 || searchQuery.length > 0) && (
124+
<Popover
125+
open={searchBoxOpen}
126+
onToggle={setSearchBoxOpen}
127+
aria-label="Search"
128+
trigger={
129+
<WithTooltip tip="Search" position="bottom">
130+
<div className="button">
131+
<Icon name="solid-search" />
132+
</div>
133+
</WithTooltip>
134+
}
135+
>
136+
<input
137+
ref={searchInputRef}
138+
value={searchQuery}
139+
autoFocus
140+
type="text"
141+
placeholder="Search followers"
142+
onChange={(evt) => setSearchQuery(evt.target.value)}
143+
/>
144+
</Popover>
145+
)}
144146
<Popover
145147
aria-label="Export"
146148
trigger={

app/views/help_center/articles/contents/_101-designing-your-product-page.html.erb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
<figure><%= image_tag "https://d33v4339jhl8k0.cloudfront.net/docs/assets/5c4657ad2c7d3a66e32d763f/images/64248bcc4cd1ab01bbe8b082/file-qFRruuIBdB.png" %></figure>
2222
<p>The custom field info will be accessible in the <a href="https://www.gumroad.com/customers">Sales tab</a> and the <a href="74-the-analytics-dashboard#sales-csv">sales CSV</a>.</p>
2323
<h3 id="More-like-this-recommendations-5J9b1">Recommend related products</h3>
24-
<p>Our <a href="334-more-like-this">Recommend related products</a> feature allows you to recommend other products from your store, products you're an affiliate of, or all of the products found on <a href="https://gumroad.com/discover">Gumroad Discover</a>!</p>p>
24+
<p>Our <a href="334-more-like-this">Recommend related products</a> feature allows you to recommend other products from your store, products you're an affiliate of, or all of the products found on <a href="https://gumroad.com/discover">Gumroad Discover</a>!</p>
2525
<figure><%= image_tag "https://d33v4339jhl8k0.cloudfront.net/docs/assets/5c4657ad2c7d3a66e32d763f/images/65c3046b0a12eb325db176e7/file-mgZ6SnjBz9.png" %></figure>
2626
<h3 id="Creating-an-Upsell-PYDkp">Creating an Upsell</h3>
2727
<p>Upsells allow you to suggest additional products to your customers at checkout. You can either nudge them to purchase an upgraded version, replace the product with another one, or add an extra product to the cart. </p>

app/views/help_center/articles/contents/_131-using-workflows-to-send-automated-updates.html.erb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@
5959
<figure><%= image_tag "https://d33v4339jhl8k0.cloudfront.net/docs/assets/5c4657ad2c7d3a66e32d763f/images/664b407972987f726dc81b5e/file-zEj6Ze1xcY.jpg" %></figure>
6060
<p>We do not send a duplicate card abandonment email every 24 hours if the customer’s cart remains abandoned.</p>
6161
<h3 id="Testing-your-workflow-z6ml8">Testing your workflow</h3>
62-
<p>You can't test a workflow as part of a <a href="62-testing-a-purchase">test purchase</a>. As a test purchase isn't a real transaction, the workflow won't be triggered.</p>p>
62+
<p>You can't test a workflow as part of a <a href="62-testing-a-purchase">test purchase</a>. As a test purchase isn't a real transaction, the workflow won't be triggered.</p>
6363
<p>Instead, you can test the workflow by creating a 100% <a href="128-discount-codes">Discount Code</a> and purchasing using another email address.</p>
6464
<h3 id="Your-audiences-experience-ZpRZS">Your audience's experience</h3>
6565
<p>Your audience will receive workflows as emails with links to any files you've attached.</p>

0 commit comments

Comments
 (0)