Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
57 commits
Select commit Hold shift + click to select a range
3ff6504
chore: config changes
up1512001 Dec 3, 2025
68bac69
FEAT: Update configuration files.
patil-vipul Dec 4, 2025
335d28c
FEAT: Update workflow files.
patil-vipul Dec 4, 2025
3b7bf6c
FEAT: Update package management files.
patil-vipul Dec 4, 2025
3ed38bc
FEAT: Update tests files
patil-vipul Dec 4, 2025
57cbdab
FEAT: Add new onboarding setup files
patil-vipul Dec 4, 2025
e2fcde4
FEAT: Update Shared Code
patil-vipul Dec 4, 2025
4ce16e1
FEAT: Module migration
patil-vipul Dec 5, 2025
f7f2b1e
FEAT: Remove legacy classes
patil-vipul Dec 5, 2025
a4c25c0
FEAT: Remove `apiConfig`
patil-vipul Dec 5, 2025
c607d44
FIX: Check for referer if origin not present.
patil-vipul Dec 5, 2025
6403771
REFACTOR: Simplify site get_site_api method
patil-vipul Dec 5, 2025
ed6fc28
REFACTOR: Make use of apiFetch
patil-vipul Dec 5, 2025
bb29d4e
REFACTOR: Remove unwanted js files
patil-vipul Dec 5, 2025
12095a5
REFACTOR: Move log script to admin dir
patil-vipul Dec 5, 2025
39cbb52
REFACTOR: Cleanup
patil-vipul Dec 5, 2025
6edc592
REFACTOR: Update docs
patil-vipul Dec 5, 2025
30caf41
REFACTOR: Align PHP doc
patil-vipul Dec 7, 2025
59f726b
REFACTOR: Align PHP doc
patil-vipul Dec 7, 2025
d5f97c9
CHORE: Make classes final which will not be extended.
patil-vipul Dec 8, 2025
f811701
FEAT: Add admin styles
patil-vipul Dec 8, 2025
e4f6ad9
FIX: Remove multisite specific code.
patil-vipul Dec 8, 2025
f99542d
chore: update docs as per onedesign
up1512001 Dec 8, 2025
5517340
add missing plugin license
up1512001 Dec 8, 2025
bb08803
update: toc as per new changes
up1512001 Dec 8, 2025
b3e1374
remove: duplicate TOC heading
up1512001 Dec 8, 2025
ee7b344
REFACTOR: Move log screen registration and script enqueueing to separ…
patil-vipul Dec 8, 2025
f7beee0
REFACTOR: Clean PHP
patil-vipul Dec 8, 2025
33406b3
FIX: Resolve Js linting issues.
patil-vipul Dec 8, 2025
e700b6b
CHORE: Update package.json
patil-vipul Dec 8, 2025
11a3b9d
REFACTOR: phpcs.xml.dist
patil-vipul Dec 8, 2025
219255c
FIX: Remove lodash and fix type errors
patil-vipul Dec 8, 2025
b876ad8
REFACTOR: Spacing fix
patil-vipul Dec 8, 2025
b526da8
REFACTOR: Multisite code cleanup
patil-vipul Dec 8, 2025
2b810e4
REFACTOR: Fix Js lint issues.
patil-vipul Dec 9, 2025
45c7b01
REFACTOR: Fix CSS lint issues.
patil-vipul Dec 9, 2025
b167da1
REFACTOR: Type errors fixed
patil-vipul Dec 9, 2025
3a10e8b
REFACTOR: Made import from react and removed unwanted code
patil-vipul Dec 9, 2025
d6bf87c
FIX: Resolve PR feedbacks
patil-vipul Dec 9, 2025
b73ca45
FIX: Shared sites API not working
patil-vipul Dec 9, 2025
094f684
FIX: PR feedbacks
patil-vipul Dec 9, 2025
a710ed8
FIX: Make use of debounce from wp/compose
patil-vipul Dec 9, 2025
7d20c86
FIX: Js types issues
patil-vipul Dec 9, 2025
1990ada
FIX: PHP Stan fixes
patil-vipul Dec 9, 2025
361bfea
FIX: PR feedbacks
patil-vipul Dec 9, 2025
a0ee1a9
FIX: Snackbar
patil-vipul Dec 9, 2025
a2da3c9
FIX: Js Types issue
patil-vipul Dec 10, 2025
b8aede3
FIX: Resolve PR Feedback
patil-vipul Dec 10, 2025
52652ea
FIX: Move OneLogs settings menu registration to Logs/Admin
patil-vipul Dec 10, 2025
51eaff8
FIX: Site name not showing
patil-vipul Dec 10, 2025
b88dea0
FIX: PR feedback
patil-vipul Dec 10, 2025
472453d
FIX: PR feedback
patil-vipul Dec 10, 2025
16e17a4
FIX: Removed unused CSS and package
patil-vipul Dec 10, 2025
ce5d826
FEAT: Added `wordpress/compose` package
patil-vipul Dec 10, 2025
3832209
REFACTOR: Removed unwanted optional chaining
patil-vipul Dec 10, 2025
0b8d1b9
REFACTOR: Indentation fix
patil-vipul Dec 10, 2025
1757392
fix: detangle Settings and Logs admin screens
justlevine Dec 10, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .eslintignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
**/*.min.js
**/node_modules/**
**/vendor/**
**/build/*
**/build/**
29 changes: 14 additions & 15 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,35 +19,34 @@
},
"globals": {
"_": true,
"patternSyncData": true
"OneLogsData": true
},
"rules": {
"eslint-comments/no-unlimited-disable": "error",
"jsdoc/check-indentation": "error",
"no-shadow": "warn",
/* WordPress surfaces snake_case keys and globals; allow them */
"camelcase": "off",
"import/no-unresolved": "off",
"import/extensions": "off",
"import/no-extraneous-dependencies": "off",
"import/default": "off",
"import/namespace": "off",
"import/no-named-as-default": "off",
"import/no-named-as-default-member": "off",
"eslint-comments/disable-enable-pair": "off",
"eslint-comments/no-unlimited-disable": "error",
"jsx-a11y/label-has-associated-control": "off",
"no-unused-vars": "off" // TODO: Fix this for flagging the types from functions.
"camelcase": "off"
},
"overrides": [
{
"files": ["**/*.{ts,tsx}"],
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaFeatures": { "jsx": true },
"sourceType": "module"
"sourceType": "module",
"project": "./tsconfig.json"
},
"plugins": ["@typescript-eslint"],
"rules": {
"no-undef": "off"
"no-undef": "off",
"no-unused-vars": "off",
"no-shadow": "off",
"@typescript-eslint/consistent-type-imports": "error",
"@typescript-eslint/no-explicit-any": "error",
"@typescript-eslint/no-shadow": "warn",
"@typescript-eslint/no-unnecessary-type-assertion": "warn",
"@typescript-eslint/no-unused-vars": "error"
}
},
{
Expand Down
20 changes: 13 additions & 7 deletions .github/workflows/copilot-setup-steps.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: 'Copilot Setup Steps'
name: "Copilot Setup Steps"

# Automatically run the setup steps when they are changed to allow for easy validation, and
# allow manual testing through the repository's "Actions" tab
Expand All @@ -21,7 +21,7 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
with:
show-progress: ${{ runner.debug == '1' && 'true' || 'false' }}
persist-credentials: false
Expand All @@ -34,18 +34,24 @@ jobs:
# dependency versions are installed and cached.
##
- name: Set up PHP
uses: shivammathur/setup-php@9e72090525849c5e82e596468b86eb55e9cc5401 # v2.32.0
uses: shivammathur/setup-php@bf6b4fbd49ca58e4608c9c89fba0b8d90bd2a39f # v2.35.5
with:
php-version: '8.3'
php-version: "8.3"
coverage: none

- name: Install Composer dependencies
uses: ramsey/composer-install@a2636af0004d1c0499ffca16ac0b4cc94df70565 # v3.1.0

- name: Setup Node
uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5.0.0
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v5.0.0
with:
cache: 'npm'
node-version-file: '.nvmrc'
cache: "npm"
node-version-file: ".nvmrc"

- name: Install NPM dependencies
run: npm ci
env:
CI: true

- name: Build assets for development
run: npm run build:dev
67 changes: 67 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
name: Upload Package on Release
permissions:
contents: write

# Cancels all previous workflow runs for pull requests that have not completed.
concurrency:
# The concurrency group contains the workflow name and the branch name for pull requests
# or the commit hash for any other events.
group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.head_ref || github.sha }}
cancel-in-progress: true

on:
release:
types: [published]

jobs:
tag:
name: Upload New Release
runs-on: ubuntu-24.04

steps:
- name: Checkout repository
uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
with:
show-progress: ${{ runner.debug == '1' && 'true' || 'false' }}
persist-credentials: false

- name: Set up PHP
uses: shivammathur/setup-php@bf6b4fbd49ca58e4608c9c89fba0b8d90bd2a39f # v2.35.5
with:
php-version: "8.3"
coverage: none
tools: composer:v2

- name: Install Composer dependencies
uses: ramsey/composer-install@3cf229dc2919194e9e36783941438d17239e8520 # v3.1.1

- name: Setup Node
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v5.0.0
with:
cache: "npm"
node-version-file: ".nvmrc"

- name: Install NPM dependencies
run: npm ci
env:
CI: true

- name: Build JavaScript assets
run: npm run build:prod

- name: Create Artifact
run: |
npm run plugin-zip

- name: Upload artifact
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
with:
name: onelogs
path: onelogs.zip

- name: Upload release asset
uses: softprops/action-gh-release@5be0e66d93ac7ed76da52eca8bb058f665c3a5fe # v2.4.2
with:
files: onelogs.zip
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
60 changes: 0 additions & 60 deletions .github/workflows/release_on_tag.yml

This file was deleted.

51 changes: 26 additions & 25 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,16 +33,16 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
with:
show-progress: ${{ runner.debug == '1' && 'true' || 'false' }}
persist-credentials: false

- name: Setup Node
uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5.0.0
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v5.0.0
with:
cache: 'npm'
node-version-file: '.nvmrc'
cache: "npm"
node-version-file: ".nvmrc"

- name: Install NPM dependencies
run: npm ci
Expand All @@ -51,8 +51,7 @@ jobs:
run: npm run lint:js

- name: Run Stylelint
# @TODO: Remove after css is restored to the project.
run: npm run lint:css -- --allow-empty-input
run: npm run lint:css

- name: Run TS Typecheck
run: npm run lint:js:types
Expand Down Expand Up @@ -80,15 +79,15 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
with:
show-progress: ${{ runner.debug == '1' && 'true' || 'false' }}
persist-credentials: false

- name: Set up PHP
uses: shivammathur/setup-php@9e72090525849c5e82e596468b86eb55e9cc5401 # v2.32.0
uses: shivammathur/setup-php@bf6b4fbd49ca58e4608c9c89fba0b8d90bd2a39f # v2.35.5
with:
php-version: '8.3'
php-version: "8.3"
coverage: none
tools: cs2pr

Expand All @@ -111,7 +110,7 @@ jobs:

- name: Run PHPCS
id: phpcs
run: composer lint:php -- --report-full --report-checkstyle=./tests/_output/phpcs-report.xml
run: composer lint -- --report-full --report-checkstyle=./tests/_output/phpcs-report.xml

- name: Show PHPCS results in PR
if: ${{ always() && steps.phpcs.outcome == 'failure' }}
Expand All @@ -138,13 +137,13 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
with:
show-progress: ${{ runner.debug == '1' && 'true' || 'false' }}
persist-credentials: false

- name: Set up PHP
uses: shivammathur/setup-php@9e72090525849c5e82e596468b86eb55e9cc5401 # v2.32.0
uses: shivammathur/setup-php@bf6b4fbd49ca58e4608c9c89fba0b8d90bd2a39f # v2.35.5
with:
php-version: 8.3
coverage: none
Expand All @@ -160,7 +159,7 @@ jobs:
uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3
with:
path: tests/_output # This is defined in the base.neon file.
key: 'phpstan-result-cache-${{ runner.os }}-date-${{ steps.get-date.outputs.date }}'
key: "phpstan-result-cache-${{ runner.os }}-date-${{ steps.get-date.outputs.date }}"
restore-keys: |
phpstan-result-cache-

Expand All @@ -172,14 +171,14 @@ jobs:

- name: Run PHP static analysis tests
id: phpstan
run: composer lint:php:stan -- -vvv --error-format=checkstyle | cs2pr
run: composer phpstan -- -vvv --error-format=checkstyle | cs2pr

- name: 'Save result cache'
- name: "Save result cache"
uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3
if: ${{ !cancelled() }}
with:
path: tests/_output
key: 'phpstan-result-cache-${{ runner.os }}-date-${{ steps.get-date.outputs.date }}'
key: "phpstan-result-cache-${{ runner.os }}-date-${{ steps.get-date.outputs.date }}"

# Runs the PHPUnit tests for WordPress.
#
Expand All @@ -197,16 +196,18 @@ jobs:
# - Uploads HTML coverage report as an artifact (if coverage is enabled).
phpunit:
name: Test PHP ${{ matrix.php }} WP ${{ matrix.wp }}${{ matrix.coverage && ' with coverage' || '' }}
permissions:
contents: read
runs-on: ubuntu-24.04
strategy:
fail-fast: false
matrix:
# Todo: reenable matrix items once repo is public.
php: ['8.4' ] #, '8.3', '8.2', '8.1', '8.0']
php: ["8.4"] #, '8.3', '8.2', '8.1', '8.0']
wp: [latest] #, trunk]
coverage: [false]
include:
- php: '8.4'
- php: "8.4"
wp: latest
coverage: true
env:
Expand All @@ -220,7 +221,7 @@ jobs:
echo "PHP_FPM_GID=$(id -g)" >> "$GITHUB_ENV"

- name: Checkout repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
with:
show-progress: ${{ runner.debug == '1' && 'true' || 'false' }}
persist-credentials: false
Expand All @@ -235,17 +236,17 @@ jobs:
- name: Set up PHP
uses: shivammathur/setup-php@9e72090525849c5e82e596468b86eb55e9cc5401 # v2.32.0
with:
php-version: '${{ matrix.php }}'
php-version: "${{ matrix.php }}"
coverage: none

- name: Install Composer dependencies
uses: ramsey/composer-install@a2636af0004d1c0499ffca16ac0b4cc94df70565 # v3.1.0

- name: Setup Node
uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5.0.0
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v5.0.0
with:
cache: 'npm'
node-version-file: '.nvmrc'
cache: "npm"
node-version-file: ".nvmrc"

- name: Install NPM dependencies
run: npm ci
Expand Down Expand Up @@ -285,8 +286,8 @@ jobs:

- name: Upload HTML coverage report as artifact
if: ${{ matrix.coverage }}
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
with:
name: wp-code-coverage-${{ matrix.php }}-${{ matrix.wp }}
path: tests/_output/html
overwrite: true
overwrite: true
Loading