Skip to content

Add new card-style OG image templates #5

Open

Description

@anurag629

This is the tracker for new templates this Hacktoberfest. Each idea below has its own issue, so pick one, comment on that issue to get assigned, and build it.

Template issues

Check your template in the editor's live preview, and with the Download PNG button too: the preview renders in the browser and the download renders on the server.

How to add a template

  1. Create src/templates/{category}/{name}.ts default-exporting a TemplateDefinition. The id must be {category}-{name} (for example, blog/minimal-dark.ts has id blog-minimal-dark).
  2. Re-export it in src/templates/{category}/index.ts.
  3. Import it and add it to the category's array in src/templates/registry.ts (append at the end of the block).
  4. Run npm run dev, open http://localhost:4321/create/{category}, pick your template, and try long text and empty optional fields.
  5. Run npm run check and npm run test. You do not need to update README counts.

Template checklist

  • Root element is width: '1200px', height: '630px'
  • Every div has display: 'flex', inline styles only, flexbox only (no grid)
  • Fonts: Inter (400/500/600/700), Playfair Display (400/700), JetBrains Mono (400/700)
  • No emoji or remote images in defaults (no emoji font is bundled)
  • Long text handled with truncate() / autoFontSize(); empty optional fields are hidden cleanly
  • Still readable on a light background: try bgColor #ffffff with a dark textColor. If the template mixes its own colors (chips, badges, muted text), isLightColor() in src/templates/utils.ts helps pick ones that work on both
  • Number and toggle params parsed defensively, since API values arrive as strings: Number(params.x), params.x === true || params.x === 'true'
  • No Math.random() or dates in render (images are cached, so output must be deterministic)
  • Clear description and 4 to 6 tags (used by the editor search and the AI template search)
  • Reuse commonFields from src/templates/utils.ts where possible
  • PR targets dev, includes a screenshot, says Closes #<issue>, and fills in the "How I Tested This" and "AI Assistance" sections

Have another idea? Open a template request and mention it here.

Activity

  1. Saifjafri212213 commented on Oct 26, 2026

    @Saifjafri212213
    Contributor

    Hi @anurag629, I'm @Saifjafri212213. All my PRs are merged and I have no open issue right now (the last were #220, #236 and #265 here, and a few in toolbelt). If you have another template or issue ready, I'd be glad to take it. I can build a template or pick up a bug in any of the three repos, whichever is most useful.

  2. anurag629 commented on Oct 26, 2026

    @anurag629
    MemberAuthor

    Hey @Saifjafri212213, I opened #272 (Rescheduled) for you. Drop a comment there and I'll assign it.

  3. Saifjafri212213 commented on Oct 26, 2026

    @Saifjafri212213
    Contributor

    Hi @anurag629, thanks for #272 and the earlier ones. I'm @Saifjafri212213, and all my ogcops and toolbelt PRs are merged. If you have another template, guide or bug ready, I'd be glad to take it. I've also asked for the Urdu translation in chatcops #55, so I have room for one more.

  4. anurag629 commented on Oct 26, 2026

    @anurag629
    MemberAuthor

    Hey @Saifjafri212213, I opened toolbelt #364 (a Markdown tables guide) for you. Drop a comment there and I'll assign it.

  5. Saifjafri212213 commented on Oct 27, 2026

    @Saifjafri212213
    Contributor

    Hi @anurag629, I'm @Saifjafri212213. I have one open PR (toolbelt #369) and no other open issue, so I have room for one more. If you have another template, guide, bug or small task ready in ogcops, toolbelt or chatcops, I'd be glad to take it. Thanks for the earlier ones.

  6. anurag629 commented on Oct 27, 2026

    @anurag629
    MemberAuthor

    Hey @Saifjafri212213, I opened toolbelt #370 (a cron expression guide) for you. Drop a comment there and I'll assign it.

  7. Saifjafri212213 commented on Oct 27, 2026

    @Saifjafri212213
    Contributor

    Hi @anurag629, thanks for #370, I've opened the PR for it (toolbelt #371). I'm @Saifjafri212213 and I have no other open issue, so I have room for one more. If you have another template, guide, bug or small task ready in ogcops, toolbelt or chatcops, I'd be glad to take it.

  8. anurag629 commented on Oct 27, 2026

    @anurag629
    MemberAuthor

    Hey @Saifjafri212213, I opened toolbelt #372 (a guide to camelCase, snake_case and kebab-case) for you. Drop a comment there and I'll assign it.

  9. sank8-2 commented on Oct 27, 2026

    @sank8-2
    Contributor

    Hi @anurag629, I'm @sank8-2. My last ogcops PR (#276, the waitlist template) merged earlier today, so I have no open issue or PR in any of the codercops repos right now and one slot free.

    If there's another template, guide or bug ready in ogcops, toolbelt or chatcops, I'd be glad to take it. Happy to wait if the queue is full.

  10. anurag629 commented on Oct 27, 2026

    @anurag629
    MemberAuthor

    Hey @sank8-2, I opened #282 (an Incident Update template) for you. Drop a comment there and I'll assign it.

  11. sank8-2 commented on Oct 27, 2026

    @sank8-2
    Contributor

    Hi @anurag629, I'm @sank8-2. #284 (the Incident Update template) merged a little while ago after your own-property fix review, so I have no open issue or PR in any of the codercops repos and one slot free.

    If there's another template, guide or bug ready in ogcops, toolbelt or chatcops, I'd be glad to take it. Happy to wait if the queue is full.

  12. anurag629 commented on Oct 27, 2026

    @anurag629
    MemberAuthor

    Hey @sank8-2, I opened #289 (an Updated Post template) for you. Drop a comment there and I'll assign it.

  13. anurag2787 commented on Oct 27, 2026

    @anurag2787
    Contributor

    Hi @anurag629 is their is any other issue i can work on?

  14. anurag629 commented on Oct 28, 2026

    @anurag629
    MemberAuthor

    Hey @anurag2787, I opened #293 (a Members Only template) for you. Drop a comment there and I'll assign it.

  15. anurag2787 commented on Oct 28, 2026

    @anurag2787
    Contributor

    Hi @anurag629 is their is more issue i can work on?

  16. anurag629 commented on Oct 28, 2026

    @anurag629
    MemberAuthor

    Hey @anurag2787, I opened #297 (a Maintainers Wanted template) for you. Drop a comment there and I'll assign it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    featureNew feature requestgood first issueGood for newcomershacktoberfestGood pick for Hacktoberfest contributorstemplatesTemplate additions and improvements

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions