Making WordPress.org


Ignore:
Timestamp:
02/08/2022 07:19:44 AM (3 years ago)
Author:
dd32
Message:

Support Forums: Add a notice above a forum if you're subscribed to it.

This also adds a notice that you've successfully unsubscribed from the item too.

See #3456.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-support/functions.php

    r11496 r11529  
    2121add_action( 'after_setup_theme', 'wporg_support_theme_support' );
    2222
    23 
    2423/**
    2524 * Swaps out the no-js for the js body class if the browser supports Javascript.
    2625 */
    2726function nojs_body_tag() {
    28             echo "<script>document.body.className = document.body.className.replace('no-js','js');</script>\n";
     27    echo "<script>document.body.className = document.body.className.replace('no-js','js');</script>\n";
    2928}
    3029add_action( 'wp_body_open', __NAMESPACE__ . '\nojs_body_tag' );
    31 
    3230
    3331/**
     
    3937function wporg_support_scripts() {
    4038
    41     wp_enqueue_style( 'forum-wp4-style', get_stylesheet_uri(), [], '20220110' );
     39    wp_enqueue_style( 'forum-wp4-style', get_stylesheet_uri(), [ 'dashicons' ], filemtime( __DIR__ . '/style.css' ) );
    4240    wp_style_add_data( 'forum-wp4-style', 'rtl', 'replace' );
    4341
Note: See TracChangeset for help on using the changeset viewer.