Releases: Convertiv/handoff-app
Adding style dictionary support
This release introduces support for AWS Style Dictionaries - https://amzn.github.io/style-dictionary/#/. Style dictionary is a widely used token format that can be compiled down to a number of application formats using the AWS Style Dictionary CLI tool.
You will find the new style dictionary output in the exported artifact at ./exported/tokens/sd
.
Changes
- Added support for Style Dictionary export.
ValueProperty
is nowToken
and it can now carry additional metadata (addedisSupportedCssProperty
metadata property).- All transformers now return data as the same
TransformerOutput
interface type. All other interfaces such asCssTransformerOutput
andScssTransformerOutput
have been removed entirely. - Updated function and variable names to be more concise and provide more information about what they do.
- Restructured the documentation app to use CSS variables in preparation for user theming. Following styles can be changed:
- Global typography, header, side nav and anchor nav. Custom user theme examples coming in the next release.
- General quality of life improvements.
Bugfix
- Updated readme to correct quickstart guide for CLI
- Fixes a bug where the integration is ejected but not read, even when the integration is set to custom.
- Remove defunct default icons from top of assets page
Changelog
- Build for 0.7.0 92a2651
- Merge pull request #60 from Convertiv/bugfix/integration-path 4a77e92
- Removing debugging 3ea29c8
- Fixing bug in custom integration read 6004aba
- Merge pull request #59 from Convertiv/release/0.7.0 575f846
- Updating changelog for 0.7.0 d795652
- Removing defunct icons from assets page bc0c8bc
- Merge pull request #57 from Convertiv/feature/style-dictionary-support dcfc47f
- Merge pull request #58 from Convertiv/CONVHAND-265-css-updates-for-documentation 0075536
- CONVHAND-265 - added default documentation theme and CSS variables. c168e6b
- Merge pull request #56 from Convertiv/docs/update-quickstart 4c0383d
- Updating readme 894a71d
- Quality of life improvements. 68d3382
- Quality of life improvements. f5eaa91
- Bugfix. 28f22b2
- ValueProperty is now a token. Updated references. Misc improvements. fd32f4c
- More improvements (mostly to util functions docs). 630e64d
- Improvements. 2cd35dd
- Design foundations suport + pipeline hooks support. d2f5902
- Added isSupportedCssProperty property into the token metadata. f84f624
- Improvements to style dictionary support. Improved the token transformers. Misc improvements. 01ddc5d
- Initial style dictionary feature support. Removed files/functions that were not used. Updated naming of some internal functions and variables for them to be more concise. d5d39c4
- Removing debugging ac0de78
Fixes two bugs with start/build
Bugfixes
- Resolves an issue with level two paths in the app not rendering right
- Resolves an issue if the project env is set to production but the app start mode is run
Commits
New API + CLI, and significant refactor to improve reliability
0.6.0 introduces two major new tools that will make it much easier to integrate Handoff with existing projects and data pipelines. This release also reorganizes the Handoff code to make the pipeline significantly more robust, easier to extend, and easier to use in existing projects. Our goal with this release is to establish a stable Typescript API as we approach a 1.0 release.
Features
Handoff CLI
Handoff now comes with a CLI toolchain that allows you to run Handoff commands in any context. This CLI replaces the installer from previous versions to scaffold up projects in a directory.
- Can be installed globally as a node binary
npm i -g handoff-app
- Run in any directory using
handoff-app <command>
- Will detect in the current working root and use that config if present
- Has sane default configs that will work for normal projects
- All configurations are sparse, so you can override a single config file and the rest of the config will inherit the defaults
- Allows users to make config or eject the default config into the current working root
- Can be run interactively to configure a project or non-interactively with
env
variables - Run
handoff-app --help
for a full list of commands - See https://github.com/Convertiv/handoff-app/blob/main/docs/cli.md for documentation
Handoff Typescript API
Handoff now exposes a full typescript API published as commonjs modules. This API will allow you to use Handoff in your Node 16+ javascript or typescript projects. With just a few lines of code you can have Handoff run programmatically.
This API supersedes and replaces the plugin architecture introduced in 0.5.0. The API call structure is maintained, but now the API can be used directly in existing Node applications and can be used with typescript.
Here's a simple example that will fetch the data down. This example expects a DEV_ACCESS_TOKEN and a FIGMA_PROJECT_ID env variable, or those to be provided in process.env
. If not supplied, they will be prompted for when the pipeline is run.
import Handoff from 'handoff-app';
const handoff = new Handoff({
title: 'Handoff Bootstrap',
integration: {
name: 'bootstrap',
version: '5.3',
},
});
await handoff.fetch();
- Fully typed API + full access to all the pipeline functions for transforming the tokens
- Methods to support fetching tokens, building the documentation app, building the integration, and running the app locally for testing
- A hook system allowing javascript functions to be passed as callbacks to be executed at points in the pipeline
// This hook will execute after the integration step and allow you to extract
// data from the pipeline and write it to a file
handoff.postIntegration((documentationObject: DocumentationObject, data: HookReturn[]) => {
const colors = documentationObject.design.color.map((color) => {
return {
name: color.name,
value: color.value,
};
});
data.push({
filename: 'colors.json',
data: JSON.stringify(colors, null, 2),
});
return data;
});
- API matches the methods of the CLI so you can script in code what you can do with the CLI
- See https://github.com/Convertiv/handoff-app/blob/main/docs/api.md for documentation
Improvements
- The handoff code base was refactored to eliminate the monorepo architecture and consolidate on a more coherent package architecture. This refactoring eliminated a number of weak points and improves reliability.
- Sharing code between the data pipeline and the Nextjs documentation app is safer
- The hook architecture introduced in 0.5 was fragile and less secure than we wanted. This reorganization makes a much more robust API, with full access to the typings
- The previous structure merged configurations in a way that could fail easily. The new architecture reads and merges the various Handoff configurations in a much more robust manor.
- Previously handoff required a folder architecture, with the proper files, and could fail if those files were moved. Now Handoff can be run in an empty directory, and can accommodate configs being added and removed during operation.
- Upgrade Nextjs from 12 to 13 providing cleaner, faster application builds
- Tailwind integration hook has been added to the pipeline
Bugfixes
- Fixes several style issues in the Bootstrap 5.3 release
- Corrects a missing caret in Bootstrap 5.2 and 5.3 selects
Changes from last Canary
- Fixing version df788f9
- Bumping cli version 70d0ca7
- 0.6.0 48d1534
- Merge pull request #54 from Convertiv/release/0.6.0 a4a18c9
- Tweaks to Changlog 5e16d2a
- Updating changelog for 277 missing select caret 5f8e180
- Merge branch 'CONVHAND-277-bootstrap-select-element-integration' into release/0.6.0 17afdc4
- Writing changelog for 0.6 5a8806d
- Cleaning up some text d2f025f
- Remove the unneded closing quote c6202d0
- Fixing small bugs in pipeline zip output for web app fdf2db3
- CONVHAND-277 - mapped and extended select form element for Bootstrap 5.2 and 5.3. b14eeef
Canary release for 0.6.0 - 8
- Fixing problem with react-highlighter types are missing 283470d
Canary release for 0.6.0 - 7
- Removing debug and adding misssing types 1e75460
Canary release for 0.6.0 - 6
- Correcting small bug in transpiling package 9451b7b
Canary 5 - resolves problems when using this in serve mode
4th Canary Release 0.6.0
- Fixing load issues running as cli 159da22
Third Canary release of 0.6.0
Fixes
- Patches a bug when running the build for bootstrap when not in a directory with npm
- Fixes an issue with prisim highlighting and babel runtime
- Patches a build issue