Skip to content

Commit

Permalink
Simplify WritingModeControl story implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
Sukhendu2002 committed Dec 9, 2024
1 parent f510d8a commit b9f3c2c
Showing 1 changed file with 1 addition and 7 deletions.
Original file line number Diff line number Diff line change
@@ -1,17 +1,13 @@
/**
* WordPress dependencies
*/
import { isRTL } from '@wordpress/i18n';
import { useState } from '@wordpress/element';

/**
* Internal dependencies
*/
import WritingModeControl from '../';

/**
* WritingModeControl component allows selecting writing mode.
*/
const meta = {
title: 'BlockEditor/WritingModeControl',
component: WritingModeControl,
Expand Down Expand Up @@ -44,9 +40,7 @@ export default meta;

export const Default = {
render: function Template( { onChange, ...args } ) {
const [ value, setValue ] = useState(
isRTL() ? 'vertical-lr' : 'vertical-rl'
);
const [ value, setValue ] = useState();

return (
<WritingModeControl
Expand Down

0 comments on commit b9f3c2c

Please sign in to comment.