Skip to main content

TextBlock

Deprecated

Product subscription app extensions won't be supported as of December 3, 2025. You should migrate existing product subscription app extensions to purchase options extensions.

TextBlock is used to render a block of text that occupies the full width available. Usually used to render paragraphs of text.

import {extend, TextBlock} from '@shopify/admin-ui-extensions';

extend('Playground', (root) => {
const textBlock = root.createComponent(TextBlock, {size: 'small', variation: 'subdued'}, 'TextBlock');

root.appendChild(textBlock);
root.mount();
});
import React from 'react';
import {extend, render, TextBlock} from '@shopify/admin-ui-extensions-react';

function App() {
return (
<TextBlock size="small" variation="subdued">
TextBlock
</TextBlock>
);
}

extend(
'Playground',
render(() => <App />),
);

optional = ?

NameTypeDescription
size?"small" | "base" | "medium" | "large" | "extraLarge"Size of the text
variation?"positive" | "negative" | "strong" | "subdued" | "code"Give text additional visual meaning

  • TextBlock is used to render a block of text that occupies the full width available. Usually used to render paragraphs of text.
  • Use variation to give visual meaning to your content and size to adjust the font size.
โœ… Do๐Ÿ›‘ Don't
Ensure that text styles are used to enhance the information provided in text.Donโ€™t rely on text style alone to convey information to merchants.

Was this page helpful?