Skip to content

Instantly share code, notes, and snippets.

<form method="POST" action="https://forms.reform.app/headless/s2Aazx/customer-success-application/71t642/submissions">
<div>
<label for="f8d5111a-10e2-44b1-9b07-70d5083ec5a6">What's your name?</label>
<input
type="text"
id="f8d5111a-10e2-44b1-9b07-70d5083ec5a6"
name="answers[f8d5111a-10e2-44b1-9b07-70d5083ec5a6]"
placeholder="Jane Smith"
required
/>
@wking-io
wking-io / app.css
Created January 30, 2023 21:09
Crunchy Data Tailwind config
@tailwind base;
@tailwind components;
@tailwind utilities;
:root {
--gray-50: 250 250 250;
--gray-100: 244 244 245;
--gray-200: 228 228 231;
--gray-300: 161 161 170;
--gray-400: 212 212 216;
@wking-io
wking-io / TagField.tsx
Created December 14, 2022 22:58
Combobox Tag field
import { Combobox } from "@headlessui/react";
import {
ChevronUpDownIcon,
PlusIcon,
XMarkIcon,
} from "@heroicons/react/24/solid";
import { useActionData, useLocation, useTransition } from "@remix-run/react";
import { useCallback, useEffect, useRef, useState } from "react";
import { useShowModal } from "~/components/impl/Modal";
@wking-io
wking-io / example.tsx
Created December 8, 2022 14:33
remix-submit-on-headlessui-switch-change
function ExampleForm() {
const submit = useSubmit()
const formRef = useRef<HTMLFormElement>(null)
const submitOnChange = useCallback(() => {
if (formRef?.current) {
submit(formRef.current, { replace: true })
}, [formRef, submit])
return (
<Form method="post" className="space-y-6">
<div>
<label
htmlFor="email"
className="block text-sm font-medium text-gray-700"
>
Email address
</label>
<div className="mt-1">
<input
/movie/$movieSlug/$socialSlug/$mediaSlug
- movie
-- $movieSlug
--- index.tsx
--- $socialSlug.tsx
--- $socialSlug.$mediaSlug.tsx
/movie/$movieSlug/$tabOne/$tabTwo
@wking-io
wking-io / thank-you.html
Last active January 11, 2022 22:12
Tailwind classes to spruce up your thank you page.
<div class="inside-article text-center max-w-xl mx-auto w-5/6 py-16">
<header class="" aria-label="Content">
<h1 class="font-extrabold text-gray-900" itemprop="headline">Thank you</h1>
</header>
<div class="entry-content" itemprop="text">
<p class="has-text-align-center"><strong>Thank you for starting your trial! We have sent you an email with your credentials.</strong><br><br>If you need any help, do not hesitate to contact us.</p>
</div>
</div>
@wking-io
wking-io / .babelrc
Created May 21, 2021 22:12
Tailwind + Phoenix Setup
{
"presets": [
"@babel/preset-env"
]
}
@wking-io
wking-io / package.json
Created May 21, 2021 22:08
Tailwind + Phoenix Setup
{
"repository": {},
"description": " ",
"license": "MIT",
"scripts": {
"deploy": "webpack --mode production",
"watch": "TAILWIND_MODE=watch NODE_ENV=development webpack --mode development --watch"
},
"dependencies": {
"phoenix": "file:../deps/phoenix",
## Params
# {
# "user" => {
# "owned_accounts_attributes" => { "0" => { "name" => "[FILTERED]" } },
# "name"=>"[FILTERED]",
# "email"=>"[FILTERED]",
# "password"=>"[FILTERED]",
# "time_zone"=>"Central Time (US & Canada)",
# "terms_of_service"=>"0"