Skip to content

Releases: prismicio/slice-machine

1.0.3

04 May 18:22
Compare
Choose a tag to compare

Improvements & bug fixes ⚙️

  • We fixed the code snippet for the embed field.
  • We fixed an issue that was letting users rename a Slice with a name starting with a number.
  • We fixed a bug preventing some users to start Slice Machine because of an invalid JSON in the ~/.prismic file.
  • We fixed a bug that was preventing some users to push changes containing Slices screenshots and receiving a 403 error.

1.0.2

28 Apr 15:43
Compare
Choose a tag to compare

Small fixes ⚙️ :

  • We fixed a bug that prevented users from pushing changes to their repository when they had a large number of Slices to push. 👉GitHub issue
  • We fixed a bug that prevented deleting Custom Types and Slices when migrating to v1.0.0 👉 Issue on Prismic Forum
  • We fixed a bug that prevented from setting image fields to "auto". 👉 GitHub issue
  • We fixed a bug that prevented Typescript to load Prismic types because of a file name conflict. 👉 GitHub issue
  • We fixed a bug that prevented custom Slices screenshots to get displayed in the new v1.0.0 of Slice Machine

1.0.0

25 Apr 09:26
Compare
Choose a tag to compare

👋

Today we're releasing a new version of Slice Machine that includes major changes to our framework integrations.

New Nuxt 3 support (and better Nuxt 2 support) ⛰

Slice Machine now officially supports Nuxt 3 and integrates more deeply with Nuxt 2.

  • The init command now scaffolds the Slice Simulator and configures the Prismic module in your Nuxt config file for you.
  • Slices are now created and typed with TypeScript or JSDoc.
  • Slice index files are now created in TypeScript if your project uses TypeScript.
  • slices/index.js|ts files can now be configured to lazy import Slices for better performance with large Slice libraries.

Better Next.js support ⏭

  • The init command now scaffolds the Slice Simulator and prismicio.js|ts file for you.
  • Slices are now created and typed with TypeScript or JSDoc.
  • Slice index files are now created in TypeScript if your project uses TypeScript.
  • slices/index.js|ts files can now be configured to lazy import Slices for better performance with large Slice libraries.

Revamped init Command 🏁

The init command has been rewritten from the ground up to offer better performance and experience.

  • To save time, dependencies will install in the background while you select your project configurations.
  • The init command now installs dependencies using the package manager used on your project (npm, Yarn, Berry, pnpm, and more).
  • The repository creation flow now suggests a name based on your project's name if available, or a random one.
  • The repository creation flow now highlights relevant considerations when choosing a repository name.
  • The repository creation flow lets you preview your dashboard and API URL.

Slice Machine rebuild 🛠️

We rewrote Slice Machine's backend to be more reliable and future-proof.

  • Framework integrations are no longer hard-coded. Instead, they are modularized via an adapter system.
  • sm.json has been renamed slicemachine.config.json.
  • The Slice Machine startup process has been redesigned and optimized.

Migration and breaking changes

Slice Machine will automatically make some changes in your codebase to migrate you to version 1.0. You do not need to do anything to upgrade, other than installing slice-machine-ui@^1.0

  • sm.json will be renamed to slicemachine.config.json, and its structure will change slightly
  • The .slicemachine folder will be removed. Mocks and screenshots will be saved alongside each slice.
  • The Storybook integration will no longer be available. It will be reintroduced at a later date.
  • JPG and JPEG screenshots are not supported anymore. See #969

0.7.1

07 Mar 15:30
Compare
Choose a tag to compare

👋

We're releasing today a new version of Slice Machine, including new fields supported in the editor in Slice Simulator and a few bug fixes.

Improvements 🌱

  • Users can now edit and save their mock data for the Link field in Slice Simulator. (Only links to web are supported for now)
  • Users can now edit and save their mock data for the Date field in Slice Simulator.

Bug fixes 🐛

  • We fixed a bug preventing users on Node 14 to rename their Slices.

0.7.0

16 Feb 14:51
Compare
Choose a tag to compare

👋

We're happy to announce our new version of Slice Machine! We are continuing to improve Slice Machine by adding a long-requested feature: Slices and Custom Types deletion.

With this version, users can delete Slices and Custom Types directly in Slice Machine. This will significantly simplify the Slice management workflow, avoiding the hassle of using the Custom Types API for Slice deletion.

Improvements 🔥

Delete Custom Types and Slices in Slice Machine

  • Users can now delete Slices directly within Slice Machine
  • Users can now delete Custom Types directly within Slice Machine
  • When you delete a Custom Type, Slice Machine will let you delete all of the associated Documents at the same time.

Push

  • Slice Machine will now push all of your changes at once.

Supporting Legacy Slices

  • Users can now import their Custom Types that include Slices built with the Legacy Builder . To do so, copy each of your Legacy Custom Type JSON models into their own sub-folders in the customtypes directory in your file system and run Slice Machine version 7 or higher.

Bug fixes 🐛

  • We removed an error that was logged in the terminal when successfully renaming a Slice.
  • We fixed a bug that was preventing users from using Storybook after renaming a Slice.

0.6.1

19 Jan 16:41
Compare
Choose a tag to compare

👋

We're making good progress toward our next big release. In the meantime, we've tackled a few bugs to make Slice Machine even more robust. If you want an update on our ongoing work, visit prismic.io/progress.

Bug fixes ⚙️

We fixed the following bugs:

  • A bug that caused an error when users tried to simulate a Slice variation that had not been saved to the file system. Users now have to save variations first
  • A bug that caused a reset of all mock data saved when you created a new variation for a Slice
  • A bug when taking a screenshot with multiple images where images didn't finish loading before the screenshot was taken and some didn't appear in the screenshot
  • A bug with the Select field that was causing an app freeze when typing fast in the field settings
  • A bug that was letting users create duplicate Custom Types and Slices tabs with the same name
  • A bug that was preventing users to move fields properly in the list

We also fixed wording issues in the login modals.

0.6.0

22 Dec 17:31
Compare
Choose a tag to compare

Improvements 👋

Edit content in the simulator 🔥

We're happy to announce the release of our new feature which allows you to edit mock data via the simulator in Slice Machine. Our editing widget shows you the mock data in your Slice and allows you to customize it however you want.

With this new feature you’ll be able to:

  • Quickly update all of your components to reflect exactly what a Slice is intended to look like with real content (creating nicer Slice screenshots)
  • Test edge cases, including content that looks different from the intended design
  • Understand the editing experience you are providing to your content teams
  • Save your mocks so you can retain the changes you as you edit your mocks and your Slice model

In the first release of this feature you’ll be able to edit the following fields:

  • Rich Text field with bold, italic, bullet list, numbered list, heading, code block, and right-to-left
  • Image field with the ability to crop
  • Select field
  • Key text field
  • Number field
  • Boolean field
  • Title field
  • Repeatable Zone

See our demo during the last Prismic Meetup :

MEETUP.EDITOR.DEMO.-.122022.1.mp4

Improving the setup and onboarding of the simulator 👌

With this new release, we are easing the setup flow to make your way to the Slice Simulator. Also, we're making error handling more simple so that you can understand when something went wrong previewing your Slices.

This new version:

  • Highlights the new "Simulate Slice" button in the Slice builder with a video tooltip to explain the value of the simulator
  • Includes the setup steps inside the simulator (removing the setup panel)
  • Includes a new error state to let users know when dev server is not running to simulate their Slice

UX improvements 💄

  • We added an ellipsis in the header bar in the Slice builder when the Slice name is too long

Setup improvement ⚙️

  • @prismicio/next is now installed automatically when running the npx @slicemachine/init script to set up Slice Machine

0.5.2

02 Nov 16:31
Compare
Choose a tag to compare

Improvements 👋

Screenshots improvements 🔥

We're happy to be releasing some improvements to the Slice screenshots. Screenshots are the best way to visually document your Slices, showing content editors what each Slice looks like.

To facilitate screenshots, we want to make the process seamless on the Slice Machine side. To that end, we've made the following improvements:

  • You can take or drag and drop screenshots from the Slices list
  • You can take or drag and drop screenshots from the Changes page
  • You can take or drag and drop screenshots per Slice variation in the new screenshots modal
  • You can take automatic screenshots from inside the simulator
  • You can set custom height and width for your screenshots in the simulator
  • You will see warnings for missing screenshots

0.5.1

18 Oct 10:22
Compare
Choose a tag to compare

Improvements 👋

TypeScript support 🔥

We are happy to announce official TypeScript support in Slice Machine. Slice Machine now automatically generates types when you create, update, or rename a Slice or a Custom Type. To use this new feature, make sure you have @prismicio/types installed.

Here are two useful resources to learn more about type generation and usage with your Slice Machine project:

Prismic.x.TypeScript.just.got.better.mp4

UX 💄

  • Buttons in Slice Machine have been reworked to keep consistent across the whole application
  • We removed the unused burger menu in all fields editing modal
  • We removed an error message shown in the Custom Type creation modal when switching from repeatable to single
  • We added an error message in the Rich Text field editing modal when no "accept" field is defined
  • We removed comments in the middle of code snippets, in the repeatable zone

Bug fixes 🚧

  • In the image field editing modal, you can now set the size of the thumbnails with only height or width

0.5.0

27 Sep 14:33
Compare
Choose a tag to compare

Improvements 👋

Pushing changes:

We have redesigned the way you will push changes to Prismic

  • Custom types and Slices are now pushed from a dedicated Changes page
  • Anything that is not pushed to Prismic will be considered a change to be pushed
  • Status of Custom types and Slices will be unknown if you can't reach the Prismic API
  • Slice Machine displays the number of changes waiting to be pushed
  • New or updated screenshots are now considered a change 🎉

Alt Text

UX improvements

  • Slice Machine shows a badge for the pushed status of each Slice and Custom Type in the Slices and Custom Types pages. When you hover the badge, a tooltip displays more information.
  • The onboarding videos are updated with new information.

Bug Fixes 🚧

  • We no longer check for the Slice Simulator setup for custom screenshots #558
  • Custom Type state is properly updated on save, no need to refresh anymore #554