Three tiers
Stable
The 123 components, 16 hooks and the helpers you import from turtlekit, with their types. Every prop in a component’s props table, and its values. The tokens: the --tk-* custom properties of the colour, type, space, size, radius, shadow and motion scales, and each palette’s 12 steps. The attributes of native elements inside <Elements>. The stable paths below.
These change only in a major release. A name is first marked deprecated in a minor release, and keeps working until the major.
Provisional
Files that work today and whose names may move: the CSS parts, the kit’s source stylesheets and token files, the font files. A name changes only in a minor release, with a line in the changelog, and never in a patch.
Internal
Everything else: the kit’s tk- class names, the data attributes its components write, and the custom properties of single components (--tk-switch-*, --tk-card-*). These can change in any release.
New components, props, values and tokens arrive in minor releases and are stable from the release that brings them. The changelog names each one.
Paths
Stable paths
turtlekit- The components, hooks and helpers.
turtlekit/styles.css- The whole stylesheet.
turtlekit/dist/css/turtlekit.css- The same file, by its longer address.
turtlekit/dist/css/turtlekit-isolated.css- The stylesheet for a screen inside another product.
turtlekit/fonts.css- The fonts alone, for the page around a widget.
turtlekit/embed- A widget on someone else’s page.
turtlekit/host- The components for a host that brings its own React.
turtlekit/dist/css/parts/manifest.json- The list of CSS parts; the same in
parts-isolated/.
Provisional paths
turtlekit/dist/css/parts/*.css- The CSS parts. Read each file’s name from the manifest: the way the stylesheet is cut may change.
turtlekit/css/*- The kit’s source stylesheets. A file may be renamed, split or merged.
turtlekit/tokens/*- The token files. The token names inside them are stable.
turtlekit/fonts/*- The font files: the kit’s own, loaded through
turtlekit/fonts.css, and the font packs, each one stylesheet,turtlekit/fonts/<id>.css, imported after the kit’s. turtlekit/dist/css/turtlekit-shadow.css- The stylesheet
mountEmbedcarries. Mount withmountEmbed.
Styling your own page
Page CSS uses your own class names and reads the kit’s tokens. On the Root’s element, .tk-root, data-tk-theme, data-accent-color and data-gray-color are stable, for the rare rule that must know the theme; the tokens already follow it.
.plan-card {
padding: var(--tk-space-4);
border-radius: var(--tk-radius-md);
border: var(--tk-border-width) solid var(--tk-color-border-subtle);
background: var(--tk-color-bg-surface);
}A component’s look is set through its props. Its class names and the attributes it writes are internal, so a rule that targets them can stop matching in any release.
Deprecated in 1.x
10 helper functions were exported in 1.0 and are the kit’s own working parts. They keep working through 1.x, show as deprecated in your editor, and leave the exports in 2.0. Each is listed with what to use in its place.
baseButtonAttributesButtonloadingContentsButtonniceTicksChartpageRangePaginationparseMonthvalidateDateplaceBelowPopoverreadThemeuseThemetabListAttributesTabListtestimonialsColumnsTestimonialstestimonialsLayoutTestimonials