$settings['card_format'], 'locale' => str_replace( '_', '-', get_user_locale() ), 'strings' => array( 'all' => __( 'All', 'showbits' ), 'clips' => __( 'Clips', 'showbits' ), 'quotes' => __( 'Quote cards', 'showbits' ), 'search' => __( 'Search titles', 'showbits' ), 'searchLabel' => __( 'Search the library', 'showbits' ), 'import' => __( 'Import selected', 'showbits' ), /* translators: 1: which one, 2: how many in all */ 'importing' => __( 'Asking ShowBits for %1$d of %2$d …', 'showbits' ), /* translators: %d: how many clips are still on their way */ 'waiting' => __( 'On the way from ShowBits: %d …', 'showbits' ), /* translators: %d: how many clips were imported */ 'done' => __( 'Imported: %d', 'showbits' ), 'later' => __( 'Not everything has arrived yet; it continues in the background. Settings → ShowBits lists the imports.', 'showbits' ), 'pending' => __( 'On the way', 'showbits' ), 'loadMore' => __( 'Load more', 'showbits' ), 'loading' => __( 'Loading …', 'showbits' ), 'empty' => __( 'No released clips or quote cards yet.', 'showbits' ), /* translators: %s: date and time the embargo ends */ 'embargo' => __( 'Embargo until %s', 'showbits' ), 'noFile' => __( 'Not ready yet', 'showbits' ), 'inLibrary' => __( 'In the media library', 'showbits' ), 'outdated' => __( 'An older version is in the media library', 'showbits' ), 'edit' => __( 'Edit', 'showbits' ), 'format' => __( 'Format', 'showbits' ), 'video' => __( 'Video', 'showbits' ), 'quote' => __( 'Quote card', 'showbits' ), 'meme' => __( 'Meme', 'showbits' ), /* translators: %s: why it failed */ 'failed' => __( 'Failed: %s', 'showbits' ), /* translators: %s: why it failed */ 'loadFailed' => __( 'The library could not be loaded: %s', 'showbits' ), ), ); wp_add_inline_script( 'showbits-library', 'window.showbitsLibrary = ' . wp_json_encode( $data ) . ';', 'before' ); } public static function render(): void { $connected = Options::connection(); echo '
' . esc_html__( 'This site is not connected to ShowBits yet.', 'showbits' ) . ' '; if ( current_user_can( 'manage_options' ) ) { echo '' . esc_html__( 'Connect it in the settings.', 'showbits' ) . ''; } else { echo esc_html__( 'An administrator of this site connects it in the settings.', 'showbits' ); } echo '
'; /* translators: %s: the ShowBits workspace's name */ echo esc_html( sprintf( __( 'Released clips and quote cards from the ShowBits workspace “%s”. What you import lands in the media library, ready for posts and pages.', 'showbits' ), Plugin::isolate( (string) $connected['workspace_name'] ) ) ); echo '
'; echo ''; echo ''; echo ''; } }