Implement Zo's direction notes: split profile/website, real SDKs, iqui kit#3
Open
mega123-art wants to merge 6 commits into
Open
Implement Zo's direction notes: split profile/website, real SDKs, iqui kit#3mega123-art wants to merge 6 commits into
mega123-art wants to merge 6 commits into
Conversation
Installs @iqlabs-official/git-sdk and rewires lib/iqlabs.ts to use GitClient from the /browser entry. The publish flow now: 1. Exports site HTML via exportSiteHtml() 2. Creates an on-chain git repo (idempotent — checks existing repos first) 3. Commits index.html + iqpages.json via client.commit() 4. Calls deployPages() to register in IQ Pages gallery 5. Returns the deployPages sig as the on-chain pointer for the SNS record Mock mode (NEXT_PUBLIC_IQ_MOCK=1) path is unchanged. lib/publish.ts updated to pass connection through to publishToIQLabs. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Profile is now a distinct product path from the website builder:
- lib/profile.ts: IQProfile type ({ version, format: 'react95', data, theme }),
5 built-in react95-format themes (IQ Dark, Windows 95, Midnight, Sakura, Hacker),
publishProfile() commits iqprofile.json to 'iq-profile' repo via git-sdk
- components/profile/theme-picker.tsx: visual theme selector with live color preview
- components/profile/profile-form.tsx: fields form (name, handle, bio, avatar, links)
- app/profile/page.tsx: full editor — theme picker + live preview + form + publish
- app/page.tsx: updated homepage with two explicit paths (Profile vs Website)
- lib/templates.ts: removed creator-profile from website gallery and TEMPLATE_DEFINITIONS
- app/templates/page.tsx: relabeled as 'Website Templates', added link to profile flow
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Three MIT-licensed builders studied for block modeling, JSON state, and HTML export — the three things IQForge's website builder needs. Each example is a minimal runnable demo showing the exact patterns relevant to IQForge. The top-level README.md captures the comparison and recommends Puck as the target for Step 4: its config-first block model mirrors IQForge's "templates are data" design, <Render /> gives clean HTML export via renderToString, and onPublish hooks directly into the git-sdk commit flow. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- lib/puck-config.tsx: IQForge block library (Hero, Text, FeatureGrid, CTA, Spacer) with inline-only styles — exported HTML is fully self-contained - lib/puck-export.ts: renderToStaticMarkup via Puck <Render> → index.html - lib/export-html.ts: branch on site.builder — Puck path or template path - lib/site-store.ts: newPuckSite() helper for visual-builder drafts - lib/iqlabs.ts: commits puck.json alongside index.html so published sites stay re-editable from chain - lib/types.ts: SiteBuilder union + Site.puckData field - app/build/website/page.tsx: 3-step flow (build → domain → publish) driven by Puck; reuses existing DomainStep + PublishStep unchanged - components/website/website-editor.tsx: thin ssr:false Puck wrapper - app/page.tsx: homepage card for Website now links to /build/website - tsconfig.json: exclude examples/ (standalone sub-projects with own deps) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Introduced the iqui UI kit with theme context, bevel utility, and components including Window, Panel, Button, and Anchor. - Implemented ProfileCard component to showcase user profiles using the iqui kit, integrating social links and profile picture.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Implements Zo's direction notes (ZO_PLAN.md) end to end. Splits the
repo into its two real products — profiles (network identity) and websites
(authored pages) — backs each with the correct published SDK, and adds an own
themeable UI kit. Everything verified against the actual upstream repos
(
IQCoreTeam/iq-wide-web,@iqlabs-official/*), not guessed.tsc --noEmitclean.next buildclean (all 8 routes).Action items from ZO_PLAN.md
@iqlabs-official/git-sdkexamples/OSS builders + build our editor (Puck)What changed
Websites — real on-chain git push (§0, §2, §3)
lib/iqlabs.tsusesGitClientfrom@iqlabs-official/git-sdk/browser. Commitsindex.html+iqpages.json(PagesConfig), thendeployPages()— the SDK'sintended pages-deploy flow. Puck source persisted as
puck.jsonso a publishedsite can be re-opened and edited from chain.
examples/study of GrapesJS / Craft.js / Puck; Puck wired as thelive editor (
lib/puck-config.tsx,lib/puck-export.ts,components/website/).Profiles — written through the real iq-wide-web system (§1)
This is the substantive correctness fix. The previous pass wrote profiles to a
git-sdk repo as
iqprofile.jsonwith a custom{version, format, data, theme}shape — which iq-wide-web cannot read. Verified against
iq-wide-web/src/lib/profile/use-profile-editor.tsand rewrote to match it exactly:ProfileMeta:{ name, bio?, profilePicture?, socials? },socialskeyed by itsSocialKeyunion(
twitter|github|website|linkedin|telegram|discord|email).iqprofile-rootDbRoot exists →writer.codeIn(json)→writer.updateUserMetadata(txId)onto the caller's user PDA. Not a git repo. Program id + root id copied from
iq-wide-web/src/lib/constants.ts(env-overridable).useProfileresolves the same wallet → this metadata, so theprofile renders identically on every IQ surface. One source of truth.
themeis kept as an additive field on the JSON — iq-wide-web'sJSON.parseignores unknown keys (it applies its own global theme), so itround-trips harmlessly while theme-aware renderers can pick it up. Honors §1's
theme intent without breaking compatibility.
components/profile/profile-form.tsx) + page (app/profile/page.tsx) updatedto the new fields.
iqui — our own themeable UI kit (§5)
components/iqui/index.tsx: same contract react95 proves — a flat color-tokenobject + a
ThemeProvider. No styled-components, no new dependency: componentsread tokens from context and render the classic raised/inset bevel via
box-shadow.Exposes
ThemeProvider,useTheme,bevel,Window,Panel,Button,Anchor,and
IQ_THEMES.components/profile/profile-card.tsxrenders the profilepreview entirely through iqui, wired into the profile page. New theme object → new
look, zero new component code — same "data not code" principle as the templates.
reference).
Build/deps fix
next buildwas failing: git-sdk's optional EVM path imports@iqlabs-official/ethereum-sdk+ethers, which were not installed. Installed thereal peer deps (
@iqlabs-official/ethereum-sdk@^0.2.2,ethers@^6.17) rather thanstubbing them out. Build now resolves the full SDK.
Verification
npx tsc --noEmit— clean, real SDK types.npx next build— clean, all 8 routes;/profilestatic-renders, exercising theiqui kit (
ThemeProvider+bevel+ every component) end to end.@iqlabs-official/solana-sdk@0.1.27already in the tree — all APIs(
writer.codeIn,writer.updateUserMetadata,contract.getDbRootPda,contract.initializeDbRootInstruction,utils.toSeedBytes) confirmed present.Not done
codeIn/deployPagesfrom a browserwallet needs a funded wallet + RPC. Code path is
NEXT_PUBLIC_IQ_MOCK=0.new color object, no new code"; add more when a specific look is wanted.
🤖 Generated with Claude Code