Skip to content

Commit 138941d

Browse files
authored
Merge pull request #297 from codesnippetspro/core-beta
Prepare release: v3.9.0
2 parents 18d4a13 + fb8c0e3 commit 138941d

26 files changed

+700
-220
lines changed

.browserslistrc

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
last 2 versions
2+
not dead
3+
Chrome >= 111
4+
Edge >= 111
5+
Firefox >= 112
6+
Safari >= 16.4
7+
Android >= 111
8+
ChromeAndroid >= 111
9+
FirefoxAndroid >= 112
10+
iOS >= 16.4

.travis.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,5 +55,5 @@ script:
5555
- find . -maxdepth 1 \( -name '*.php' \) -exec php -lf {} \;
5656
- find src/php/ \( -name '*.php' \) -exec php -lf {} \;
5757

58-
# Run tests
59-
- npm run test
58+
# Run linters
59+
- npm run lint

CHANGELOG.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,28 @@
11
# Changelog
22

3+
## [3.9.0-beta.2] (2025-11-10)
4+
5+
### Added
6+
* Added 'Snippets' row action to the Network Sites table
7+
* Improved snippet name visibility for network users
8+
9+
### Changed
10+
* Refined badge styling and hover effects for row actions and badges
11+
* Impoved icon style and color usage for network snippets for clearer differentiation
12+
13+
### Fixed
14+
* Improved network snippets management with better subsite menu permission checks
15+
* Fixed status labels for shared network snippets
16+
* Corrected network condition checks and improved snippet fetching logic
17+
* Handled fatal errors in file-based snippets to prevent crashes
18+
19+
## [3.9.0-beta.1] (2025-11-03)
20+
21+
### Added
22+
* Soft delete (Trash) functionality for snippets with ability to undo, restore or permanently delete.
23+
* Bulk actions for trashing, restoring, and permanently deleting multiple snippets.
24+
* Separate filtered view to manage trashed snippets.
25+
326
## [3.8.2] (2025-10-31)
427

528
### Fixed

eslint.config.mjs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,10 +30,10 @@ export default eslintTs.config(
3030
},
3131
{
3232
languageOptions: {
33-
ecmaVersion: 2018,
33+
ecmaVersion: 2022,
3434
globals: { ...globals.browser },
3535
parserOptions: {
36-
ecmaVersion: 2018,
36+
ecmaVersion: 2022,
3737
ecmaFeatures: { jsx: true },
3838
tsconfigRootDir: import.meta.dirname,
3939
projectService: { allowDefaultProject: ['eslint.config.mjs'] }

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,12 @@
22
"name": "code-snippets",
33
"description": "Manage code snippets running on a WordPress-powered site through a graphical interface.",
44
"homepage": "https://codesnippets.pro",
5-
"version": "3.8.2",
5+
"version": "3.9.0-beta.2",
66
"main": "src/dist/edit.js",
77
"directories": {
88
"test": "tests"
99
},
1010
"scripts": {
11-
"test": "npm run stylelint && eslint && npm run phpcs",
1211
"test:playwright": "playwright test -c tests/playwright/playwright.config.ts",
1312
"test:playwright:debug": "npm run test:playwright -- --debug",
1413
"test:playwright:ui": "npm run test:playwright -- --ui",
@@ -20,9 +19,13 @@
2019
"build": "webpack",
2120
"watch": "webpack --watch",
2221
"bundle": "ts-node scripts/bundle.ts",
23-
"phpcs": "src/vendor/bin/phpcs -s --colors ./src/phpcs.xml",
24-
"phpcbf": "src/vendor/bin/phpcbf ./src/phpcs.xml",
25-
"stylelint": "stylelint --fix 'src/css/**/*.scss'",
22+
"lint": "npm run lint:styles && npm run lint:js && npm run lint:php",
23+
"lint:styles": "stylelint 'src/css/**/*.scss'",
24+
"lint:styles:fix": "stylelint --fix 'src/css/**/*.scss'",
25+
"lint:js": "eslint",
26+
"lint:js:fix": "eslint --fix",
27+
"lint:php": "src/vendor/bin/phpcs -s --colors ./src/phpcs.xml",
28+
"lint:php:fix": "src/vendor/bin/phpcbf ./src/phpcs.xml",
2629
"version": "ts-node scripts/version.ts",
2730
"version-dev": "npm version --git-tag-version=false --preid=dev",
2831
"version-alpha": "npm version --git-tag-version=false --preid=alpha",

src/code-snippets.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,11 @@
88
* License: GPL-2.0-or-later
99
* License URI: license.txt
1010
* Text Domain: code-snippets
11-
* Version: 3.8.2
11+
* Version: 3.9.0-beta.2
1212
* Requires PHP: 7.4
1313
* Requires at least: 5.0
1414
*
15-
* @version 3.8.2
15+
* @version 3.9.0-beta.2
1616
* @package Code_Snippets
1717
* @author Shea Bunge <shea@codesnippets.pro>
1818
* @copyright 2012-2024 Code Snippets Pro
@@ -37,7 +37,7 @@
3737
*
3838
* @const string
3939
*/
40-
define( 'CODE_SNIPPETS_VERSION', '3.8.2' );
40+
define( 'CODE_SNIPPETS_VERSION', '3.9.0-beta.2' );
4141

4242
/**
4343
* The full path to the main file of this plugin.

src/composer.lock

Lines changed: 32 additions & 33 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/css/common/_badges.scss

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,13 +20,27 @@
2020
gap: 5px;
2121
line-height: 1;
2222

23+
@at-root .row-actions & {
24+
color: #8c8c8c;
25+
padding-inline: 0px;
26+
text-transform: capitalize;
27+
font-weight: 500;
28+
}
29+
2330
.dashicons {
2431
font-size: 18px;
2532
inline-size: 18px;
2633
block-size: 18px;
2734
}
2835
}
2936

37+
.network-shared {
38+
color: #2271b1;
39+
font-size: 22px;
40+
width: 100%;
41+
cursor: help;
42+
}
43+
3044
.small-badge {
3145
block-size: auto;
3246
inline-size: auto;
@@ -73,6 +87,33 @@
7387
.inverted-badges .badge {
7488
color: #fff;
7589
background-color: #a7aaad;
90+
border-color: #fff !important;
91+
92+
.dashicons {
93+
color: #fff;
94+
}
95+
}
96+
97+
.nav-tab-inactive {
98+
$colors: map.get(theme.$badges, 'pro');
99+
$text-color: list.nth($colors, 2);
100+
$background-color: list.nth($colors, 1);
101+
102+
.badge.pro-badge {
103+
color: $text-color;
104+
background-color: $background-color;
105+
}
106+
107+
&:hover {
108+
&.button, .dashicons-external {
109+
color: #3c434a;
110+
}
111+
112+
.badge.pro-badge {
113+
color: $background-color;
114+
background-color: $text-color;
115+
}
116+
}
76117
}
77118

78119
.nav-tab-inactive {

src/css/common/_switch.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ a.snippet-condition-count {
9292

9393
&:hover {
9494
border-inline-start-color: theme.$accent;
95-
transition: border-left-color 0.6s;
95+
transition: border-inline-start-color 0.6s;
9696

9797
&::before {
9898
border-color: theme.$accent;

0 commit comments

Comments
 (0)