Instead I’m going to revisit the post I wrote at the end of last year. In it, I mentioned getting engaged, and this year, we got married ❤️Continue reading “Last post of 2019”
A few days ago, I started this thread on twitter…
reading this report on disability & AI, and I’d highly recommend at least the first few pages to anyone working in tech– raises some great questions, then goes into definitions around disability and technology that might challenge how you think…
Here’s the report I’m talking about: Disability, Bias, and AI [PDF]
In particular, the definition of “Assistive Technology” made me think- it helped solidify something I’ve been thinking about but unable to articulate. The basic definition is “assistive technology is shorthand for technology that assists disabled people.” Continue reading “The words we use in #a11y”
When I started the recipe block, I knew that I wanted to allow control over the section heading levels. I felt it wouldn’t be possible to assume fixed heading levels – should the Recipe Title be an h2, and the “ingredients” heading be h3? What if the post title is the recipe title, and the Recipe Title block is deleted?
First, I solved this by copying down the
HeadingToolbar component. This let me use the same heading options that the heading block uses. Unfortunately, these would always show in the block’s toolbar, regardless of whether you’re editing the title or the list content.
In my previous post, I described using InnerBlocks to create a template and restrict the blocks allowed in “parent block”. This post is kind of the reverse 🙂
When writing the Recipe Block, I wanted to allow for repeating fields of ingredients and directions. I thought the best way for this would be to make each section blocks as well, but I didn’t want them available to the editor in general.Continue reading “Nifty Code #2: Block parents”
A new series I’m hoping to write this year, full of cool things you can do in the block editor or in JS in general. Some of this has been written about before, but I’ll also point out the use in projects I’m working on. 👩🏼💻
When writing the Recipe Block, I wanted to set out a “recipe post” framework, but not lock people into a fixed format. If you use it, you’ll see that inserting the block inserts a few blocks, including an image, title, ingredients, etc. But maybe you don’t have photos, or you want to add a video. If you try to insert a new block inside the “Recipe” container, you’ll see a restricted set of blocks, mostly things that would make sense – text, video, gallery… but not another Recipe block, or Latest Comments, etc.
This is thanks to a combination of the
<InnerBlocks /> component, with the