CtrlK
BlogDocsLog inGet started
Tessl Logo

likethemammal/emotion-required

Enforce Emotion (@emotion/styled and @emotion/react) as the only styling library; forbid styled-components usage.

95

1.61x
Quality

97%

Does it follow best practices?

Impact

92%

1.61x

Average score across 4 eval scenarios

SecuritybySnyk

Passed

No known issues

Overview
Quality
Evals
Security
Files

task.mdevals/scenario-2/

Theme-Aware Storybook Decorator

Problem/Feature Description

The team is adding a new set of UI components to the shared component library and wants to author Storybook stories for each of them. The stories need to be rendered with the full project theme — including brand colors, web fonts, and global baseline styles — so that the design team can review components in context. Without the theme wired in, components render with fallback defaults that don't represent the real product.

An engineer needs to create a Storybook decorator that wraps every story in the appropriate theme context. The decorator should accept an optional theme prop so that individual stories can opt into a light or dark variant. It should compose cleanly with the existing story file format.

Output Specification

Produce a withStyling.js decorator file (e.g., at src/config/storybook/decorators/withStyling.js) that exports a default function. The decorator should be a higher-order function that takes optional decorator arguments (like { theme }) and returns a function that wraps the Story component in the correct provider. Also produce a brief example.stories.js file that demonstrates registering the decorator and writing one example story using it.

evals

SKILL.md

tile.json