title( __( 'Pages', 'desktop-mode' ) ) ->icon( 'dashicons-admin-page' ) ->size( 1100, 720 ) ->min_size( 720, 480 ) // The Pages dock tile is WordPress's own; the shell's URL remap // routes `edit.php?post_type=page` here under `nativePagesEnabled`. ->placement( 'none' ) ->can( static function () { return openstation_pages_window_user_can_register(); } ) ->config( static function () { return openstation_pages_app_config(); } ) ->state( openstation_posts_app_state( 'menu_order', 'asc' ) ) ->action( 'filter', static function ( State $state ) { openstation_posts_app_filter( $state ); } ) ->action( 'page', static function ( State $state, Os $os, array $args ) { openstation_posts_app_page( $state, $args ); } ) ->action( 'sort', static function ( State $state, Os $os, array $args ) { openstation_posts_app_sort( $state, $args, 'menu_order', 'asc' ); } ) ->action( 'trash', static function ( State $state, Os $os, array $args ) { openstation_posts_app_trash( $os, $args, 'page' ); } ) ->watch( 'page' ) ->data( static function ( State $state ) { return openstation_posts_app_data( 'wp/v2/pages', openstation_pages_window_default_query_args(), $state ); } );