GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — wip: black · coty/opencode@e146083

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • packages/console/app/src/routes/black
    • index.css
    • index.tsx
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎packages/console/app/src/routes/black/index.css‎

Copy file name to clipboardExpand all lines: packages/console/app/src/routes/black/index.css
+188Lines changed: 188 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,13 +131,201 @@
131131
text-decoration: none;
132132
}
133133

134+
[data-slot="pricing"] {
135+
display: flex;
136+
flex-direction: column;
137+
gap: 16px;
138+
width: 100%;
139+
max-width: 540px;
140+
padding: 0 20px;
141+
142+
@media (min-width: 768px) {
143+
padding: 0;
144+
}
145+
}
146+
147+
[data-slot="pricing-card"] {
148+
display: flex;
149+
flex-direction: column;
150+
gap: 12px;
151+
padding: 20px;
152+
border: 1px solid rgba(255, 255, 255, 0.17);
153+
border-radius: 4px;
154+
text-decoration: none;
155+
transition: border-color 0.15s ease;
156+
background: transparent;
157+
cursor: pointer;
158+
text-align: left;
159+
160+
&:hover {
161+
border-color: rgba(255, 255, 255, 0.35);
162+
}
163+
164+
[data-slot="icon"] {
165+
color: rgba(255, 255, 255, 0.59);
166+
}
167+
168+
[data-slot="price"] {
169+
display: flex;
170+
flex-wrap: wrap;
171+
align-items: baseline;
172+
gap: 8px;
173+
}
174+
175+
[data-slot="amount"] {
176+
color: rgba(255, 255, 255, 0.92);
177+
font-size: 24px;
178+
font-weight: 500;
179+
}
180+
181+
[data-slot="period"] {
182+
color: rgba(255, 255, 255, 0.59);
183+
font-size: 14px;
184+
}
185+
186+
[data-slot="multiplier"] {
187+
color: rgba(255, 255, 255, 0.39);
188+
font-size: 14px;
189+
190+
&::before {
191+
content: "·";
192+
margin-right: 8px;
193+
}
194+
}
195+
}
196+
197+
[data-slot="selected-plan"] {
198+
display: flex;
199+
flex-direction: column;
200+
gap: 32px;
201+
width: fit-content;
202+
max-width: calc(100% - 40px);
203+
margin: 0 auto;
204+
}
205+
206+
[data-slot="selected-card"] {
207+
display: flex;
208+
flex-direction: column;
209+
gap: 16px;
210+
padding: 20px;
211+
border: 1px solid rgba(255, 255, 255, 0.17);
212+
border-radius: 4px;
213+
width: fit-content;
214+
215+
[data-slot="icon"] {
216+
color: rgba(255, 255, 255, 0.59);
217+
}
218+
219+
[data-slot="price"] {
220+
display: flex;
221+
flex-wrap: wrap;
222+
align-items: baseline;
223+
gap: 8px;
224+
}
225+
226+
[data-slot="amount"] {
227+
color: rgba(255, 255, 255, 0.92);
228+
font-size: 24px;
229+
font-weight: 500;
230+
}
231+
232+
[data-slot="period"] {
233+
color: rgba(255, 255, 255, 0.59);
234+
font-size: 14px;
235+
}
236+
237+
[data-slot="multiplier"] {
238+
color: rgba(255, 255, 255, 0.39);
239+
font-size: 14px;
240+
241+
&::before {
242+
content: "·";
243+
margin-right: 8px;
244+
}
245+
}
246+
247+
[data-slot="terms"] {
248+
list-style: none;
249+
padding: 0;
250+
margin: 0;
251+
display: flex;
252+
flex-direction: column;
253+
gap: 12px;
254+
text-align: left;
255+
256+
li {
257+
color: rgba(255, 255, 255, 0.59);
258+
font-size: 13px;
259+
line-height: 1.5;
260+
padding-left: 16px;
261+
position: relative;
262+
white-space: nowrap;
263+
264+
&::before {
265+
content: "▪";
266+
position: absolute;
267+
left: 0;
268+
color: rgba(255, 255, 255, 0.39);
269+
}
270+
}
271+
}
272+
273+
[data-slot="actions"] {
274+
display: flex;
275+
gap: 16px;
276+
margin-top: 8px;
277+
278+
button,
279+
a {
280+
flex: 1;
281+
display: inline-flex;
282+
height: 48px;
283+
padding: 0 16px;
284+
justify-content: center;
285+
align-items: center;
286+
border-radius: 4px;
287+
font-family: var(--font-mono);
288+
font-size: 16px;
289+
font-weight: 400;
290+
text-decoration: none;
291+
cursor: pointer;
292+
}
293+
294+
[data-slot="cancel"] {
295+
background: transparent;
296+
border: 1px solid rgba(255, 255, 255, 0.17);
297+
color: rgba(255, 255, 255, 0.92);
298+
299+
&:hover {
300+
border-color: rgba(255, 255, 255, 0.35);
301+
}
302+
}
303+
304+
[data-slot="continue"] {
305+
background: rgba(255, 255, 255, 0.17);
306+
border: 1px solid rgba(255, 255, 255, 0.17);
307+
color: rgba(255, 255, 255, 0.59);
308+
309+
&:hover {
310+
background: rgba(255, 255, 255, 0.25);
311+
}
312+
}
313+
}
314+
}
315+
134316
[data-slot="fine-print"] {
135317
color: rgba(255, 255, 255, 0.39);
136318
text-align: center;
137319
font-size: 13px;
138320
font-style: normal;
139321
font-weight: 400;
140322
line-height: 160%; /* 20.8px */
323+
font-style: italic;
324+
325+
a {
326+
color: rgba(255, 255, 255, 0.39);
327+
text-decoration: underline;
328+
}
141329
}
142330
}
143331
}
Collapse file

‎packages/console/app/src/routes/black/index.tsx‎

Copy file name to clipboardExpand all lines: packages/console/app/src/routes/black/index.tsx
+103-15Lines changed: 103 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,54 @@
1-
import { A, createAsync } from "@solidjs/router"
1+
import { A, createAsync, useSearchParams } from "@solidjs/router"
22
import "./index.css"
33
import { Title } from "@solidjs/meta"
44
import { github } from "~/lib/github"
5-
import { createMemo, Match, Switch } from "solid-js"
5+
import { createMemo, createSignal, For, Match, Show, Switch } from "solid-js"
66
import { config } from "~/config"
77

8+
const plans = [
9+
{ id: "20", amount: 20, multiplier: null },
10+
{ id: "100", amount: 100, multiplier: "6x more usage than Black 20" },
11+
{ id: "200", amount: 200, multiplier: "21x more usage than Black 20" },
12+
] as const
13+
14+
function PlanIcon(props: { plan: string }) {
15+
return (
16+
<Switch>
17+
<Match when={props.plan === "20"}>
18+
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
19+
<rect x="4" y="4" width="16" height="16" rx="2" stroke="currentColor" stroke-width="1.5" />
20+
</svg>
21+
</Match>
22+
<Match when={props.plan === "100"}>
23+
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
24+
<rect x="3" y="3" width="7" height="7" rx="1" stroke="currentColor" stroke-width="1.5" />
25+
<rect x="14" y="3" width="7" height="7" rx="1" stroke="currentColor" stroke-width="1.5" />
26+
<rect x="3" y="14" width="7" height="7" rx="1" stroke="currentColor" stroke-width="1.5" />
27+
<rect x="14" y="14" width="7" height="7" rx="1" stroke="currentColor" stroke-width="1.5" />
28+
</svg>
29+
</Match>
30+
<Match when={props.plan === "200"}>
31+
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
32+
<rect x="2" y="2" width="4" height="4" rx="0.5" stroke="currentColor" stroke-width="1" />
33+
<rect x="10" y="2" width="4" height="4" rx="0.5" stroke="currentColor" stroke-width="1" />
34+
<rect x="18" y="2" width="4" height="4" rx="0.5" stroke="currentColor" stroke-width="1" />
35+
<rect x="2" y="10" width="4" height="4" rx="0.5" stroke="currentColor" stroke-width="1" />
36+
<rect x="10" y="10" width="4" height="4" rx="0.5" stroke="currentColor" stroke-width="1" />
37+
<rect x="18" y="10" width="4" height="4" rx="0.5" stroke="currentColor" stroke-width="1" />
38+
<rect x="2" y="18" width="4" height="4" rx="0.5" stroke="currentColor" stroke-width="1" />
39+
<rect x="10" y="18" width="4" height="4" rx="0.5" stroke="currentColor" stroke-width="1" />
40+
<rect x="18" y="18" width="4" height="4" rx="0.5" stroke="currentColor" stroke-width="1" />
41+
</svg>
42+
</Match>
43+
</Switch>
44+
)
45+
}
46+
847
export default function Black() {
48+
const [params] = useSearchParams()
49+
const [selected, setSelected] = createSignal<string | null>(params.plan as string | null)
50+
const selectedPlan = createMemo(() => plans.find((p) => p.id === selected()))
51+
952
const githubData = createAsync(() => github())
1053
const starCount = createMemo(() =>
1154
githubData()?.stars
@@ -16,9 +59,6 @@ export default function Black() {
1659
: config.github.starsFormatted.compact,
1760
)
1861

19-
// TODO: Frank, toggle this based on availability
20-
const available = false
21-
2262
return (
2363
<div data-page="black">
2464
<Title>opencode</Title>
@@ -148,17 +188,65 @@ export default function Black() {
148188
<p data-slot="subheading">Including Claude, GPT, Gemini, and more</p>
149189
</div>
150190
<Switch>
151-
<Match when={available}>
152-
<a href="/black/subscribe" data-slot="button">
153-
Subscribe $200/mo
154-
</a>
155-
<p data-slot="fine-print">Fair usage limits apply</p>
191+
<Match when={!selected()}>
192+
<div data-slot="pricing">
193+
<For each={plans}>
194+
{(plan) => (
195+
<button type="button" onClick={() => setSelected(plan.id)} data-slot="pricing-card">
196+
<div data-slot="icon">
197+
<PlanIcon plan={plan.id} />
198+
</div>
199+
<p data-slot="price">
200+
<span data-slot="amount">${plan.amount}</span> <span data-slot="period">per month</span>
201+
<Show when={plan.multiplier}>
202+
<span data-slot="multiplier">{plan.multiplier}</span>
203+
</Show>
204+
</p>
205+
</button>
206+
)}
207+
</For>
208+
</div>
209+
<p data-slot="fine-print">
210+
Prices shown don't include applicable tax · <A href="/legal/terms-of-service">Terms of Service</A>
211+
</p>
156212
</Match>
157-
<Match when={!available}>
158-
<p data-slot="back-soon">We’ll be back soon with more availability.</p>
159-
<a data-slot="follow-us" href="https://x.com/opencode" target="_blank">
160-
Follow @opencode
161-
</a>
213+
<Match when={selectedPlan()}>
214+
{(plan) => (
215+
<div data-slot="selected-plan">
216+
<div data-slot="selected-card">
217+
<div data-slot="icon">
218+
<PlanIcon plan={plan().id} />
219+
</div>
220+
<p data-slot="price">
221+
<span data-slot="amount">${plan().amount}</span>{" "}
222+
<span data-slot="period">per person billed monthly</span>
223+
<Show when={plan().multiplier}>
224+
<span data-slot="multiplier">{plan().multiplier}</span>
225+
</Show>
226+
</p>
227+
<ul data-slot="terms">
228+
<li>Your subscription will not start immediately</li>
229+
<li>You will be added to the waitlist and activated soon</li>
230+
<li>Your card will be only charged when your subscription is activated</li>
231+
<li>Usage limits apply, heavily automated use may reach limits sooner</li>
232+
<li>Subscriptions for individuals, contact Enterprise for teams</li>
233+
<li>Limits may be adjusted and plans may be discontinued in the future</li>
234+
<li>Cancel your subscription at anytime</li>
235+
</ul>
236+
<div data-slot="actions">
237+
<button type="button" onClick={() => setSelected(null)} data-slot="cancel">
238+
Cancel
239+
</button>
240+
<a href={`/black/subscribe?plan=${plan().id}`} data-slot="continue">
241+
Continue
242+
</a>
243+
</div>
244+
</div>
245+
<p data-slot="fine-print">
246+
Prices shown don't include applicable tax · <A href="/legal/terms-of-service">Terms of Service</A>
247+
</p>
248+
</div>
249+
)}
162250
</Match>
163251
</Switch>
164252
</section>

0 commit comments

Comments
0 (0)
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.