Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove font management #595

Merged
merged 11 commits into from
Apr 25, 2024
Merged

Remove font management #595

merged 11 commits into from
Apr 25, 2024

Conversation

vcanales
Copy link
Member

Removes font management code, since this functionality has been replaced by the native Font Library in Core, and therefore been deprecated.

This decouples the removal of font management from the removal of other deprecated parts of the Plugin, which is proposed in #528 but is on hold pending feature parity with the features in the editor, and an admin page that points to the new workflow.

Testing

Make sure that the following commands run without errors:

  1. Lint
    npm run lint:php && npm run lint:js

  2. Build
    npm run build and/or npm run start

  3. Test
    npm run test:php && npm run test:unit

After the above, load the Plugin into your dev environment and make sure that no errors are present in the Admin, editor, and in the browser's DevTools Console.

: '',
} );
}, [] );
useSelect(
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a lint autofix.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the only change to create-panel but now I'm seeing an error thrown.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I rolled it back to what's in trunk and the error is gone.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I rolled this back so that the branch was in a working state...
This change broke the app and I'm not sure why. I also attempted to remove the array rather than add theme to it with the same problem.

I'm not sure how to proceed but my 'druthers is to leave the warning for now.

@pbking
Copy link
Contributor

pbking commented Apr 25, 2024

There are still SOME font things that CBT does to manage the fonts on save and export. I've returned those to the codebase along with the tests.

I also removed some files not used as well as a few functions from the util.js. The only unit test that was in place was for a function removed so rather than dismantling the unit test framework I just stuck a sample test in there for now. (I still don't think there's anything valuable to test in the view right now, but there might be someday.)

Lastly, I returned the create-panel.js to how it was on /trunk. THe change caused the create panel to break for me when I tried to use it with the change. Comments about that above.

Copy link
Contributor

@pbking pbking left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As this exists now I think it's good to come in.

@vcanales vcanales merged commit 9ff52eb into trunk Apr 25, 2024
2 checks passed
@vcanales vcanales deleted the remove-font-management branch April 25, 2024 18:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
2 participants