Skip to content

Commit

Permalink
Merge pull request #618 from newfold-labs/fix/classnames
Browse files Browse the repository at this point in the history
Fix/classnames
  • Loading branch information
circlecube authored Jul 3, 2024
2 parents 79fd73a + 16fb2fa commit ccb3b41
Show file tree
Hide file tree
Showing 14 changed files with 31 additions and 99 deletions.
6 changes: 3 additions & 3 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -83,16 +83,16 @@
"newfold-labs/wp-module-global-ctb": "^1.0.13",
"newfold-labs/wp-module-help-center": "^2.0.0",
"newfold-labs/wp-module-loader": "^1.0.10",
"newfold-labs/wp-module-marketplace": "^2.3.1",
"newfold-labs/wp-module-marketplace": "^2.4.0",
"newfold-labs/wp-module-migration": "^1.0.8",
"newfold-labs/wp-module-notifications": "^1.3.0",
"newfold-labs/wp-module-notifications": "^1.4.0",
"newfold-labs/wp-module-onboarding": "^2.3.5",
"newfold-labs/wp-module-patterns": "2.0.0 as 1.9.9",
"newfold-labs/wp-module-performance": "2.0.0 as 1.9.9",
"newfold-labs/wp-module-runtime": "^1.0.11",
"newfold-labs/wp-module-secure-passwords": "^1.1.1",
"newfold-labs/wp-module-sso": "^1.0.5",
"newfold-labs/wp-module-staging": "^2.0.0",
"newfold-labs/wp-module-staging": "^2.1.0",
"wp-forge/wp-update-handler": "^1.0.2",
"wp-forge/wp-upgrade-handler": "^1.0"
}
Expand Down
38 changes: 19 additions & 19 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 0 additions & 14 deletions src/app/components/accordion/index.js

This file was deleted.

33 changes: 0 additions & 33 deletions src/app/components/accordion/stylesheet.scss

This file was deleted.

1 change: 0 additions & 1 deletion src/app/components/action-field/index.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { Button, Label } from '@newfold/ui-component-library';
import classNames from 'classnames';

const ActionField = ( {
label,
Expand Down
2 changes: 0 additions & 2 deletions src/app/components/app-nav/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import { useEffect, useState } from '@wordpress/element';
import apiFetch from '@wordpress/api-fetch';
import { useViewportMatch } from '@wordpress/compose';
import { addQueryArgs } from '@wordpress/url';
import classnames from 'classnames';
import { filter } from 'lodash';
import { Modal, SidebarNavigation } from '@newfold/ui-component-library';
import { default as NewfoldNotifications } from '@modules/wp-module-notifications/assets/js/components/notifications/';
Expand Down Expand Up @@ -171,7 +170,6 @@ export const SideNav = () => {
methods={ {
apiFetch,
addQueryArgs,
classnames,
filter,
useState,
useEffect,
Expand Down
6 changes: 3 additions & 3 deletions src/app/components/app-nav/logo.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Button } from '@wordpress/components';
import { Heading } from '..';
import { Title } from '@newfold/ui-component-library';
import { ReactComponent as Brand } from '../../../../assets/svg/nav-for-light.svg';
import { delay } from 'lodash';

Expand Down Expand Up @@ -27,9 +27,9 @@ const Logo = () => {
return (
<div className="hgwp-logo-wrap">
<Mark />
<Heading level="2" className="screen-reader-text">
<Title as="h2" className="screen-reader-text">
{ __( 'Hostgator WordPress Plugin', 'wp-plugin-hostgator' ) }
</Heading>
</Title>
</div>
);
};
Expand Down
6 changes: 3 additions & 3 deletions src/app/components/errorCard/index.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import './stylesheet.scss';
import { Heading } from '../../components';
import { Title } from '@newfold/ui-component-library';
import { dispatchUpdateSnackbar } from '../../util/helpers';
import {
Card,
Expand All @@ -15,7 +15,7 @@ const ErrorCard = ( { error, className, notice = 'Error!' } ) => {
return (
<Card className={ classNames( 'error-card', className ) }>
<CardHeader>
<Heading level="3">
<Title as="h3">
<Dashicon
icon="warning"
style={ {
Expand All @@ -25,7 +25,7 @@ const ErrorCard = ( { error, className, notice = 'Error!' } ) => {
} }
/>{ ' ' }
{ __( 'Oh No, An Error!', 'wp-plugin-hostgator' ) }
</Heading>
</Title>
</CardHeader>
<CardBody>
<p>
Expand Down
11 changes: 0 additions & 11 deletions src/app/components/heading/index.js

This file was deleted.

2 changes: 0 additions & 2 deletions src/app/components/index.js
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
export { default as Accordion } from './accordion';
export { default as ErrorCard } from './errorCard';
export { default as Heading } from './heading';
3 changes: 1 addition & 2 deletions src/app/pages/admin/index.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
import classNames from 'classnames';
import { Container, Page } from '@newfold/ui-component-library';
import HelpCenterSettings from '../settings/helpCenterSettings';
import WonderBlocksSettings from '../settings/wonderBlocksSettings';
import StagingFeatureSettings from '../settings/stagingFeatureSettings';
import PerformanceFeatureSettings from '../settings/performanceFeatureSettings';
import { Container, Page } from '@newfold/ui-component-library';

const Admin = () => {
return (
Expand Down
3 changes: 1 addition & 2 deletions src/app/pages/marketplace/index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import apiFetch from '@wordpress/api-fetch';
import { useState, useEffect } from '@wordpress/element';
import { useLocation, useMatch, useNavigate } from 'react-router-dom';
import classnames from 'classnames';
import { Container, Page } from '@newfold/ui-component-library';
import { NewfoldRuntime } from '@newfold-labs/wp-module-runtime';
// component sourced from marketplace module
Expand Down Expand Up @@ -43,7 +42,7 @@ const MarketplacePage = () => {
// methods to pass to module
const moduleMethods = {
apiFetch,
classnames,
classNames,
useState,
useEffect,
useLocation,
Expand Down
2 changes: 0 additions & 2 deletions src/app/pages/performance/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import AppStore from '../../data/store';
import { Container, Page } from '@newfold/ui-component-library';
import { useState, useEffect, useContext, Fragment } from '@wordpress/element';
import apiFetch from '@wordpress/api-fetch';
import classnames from 'classnames';
import { useUpdateEffect } from 'react-use';
import { NewfoldRuntime } from '@newfold-labs/wp-module-runtime';
import { useNotification } from 'App/components/notifications';
Expand Down Expand Up @@ -101,7 +100,6 @@ const PerformancePage = () => {
// methods to pass to module
const moduleMethods = {
apiFetch,
classnames,
useState,
useEffect,
useContext,
Expand Down
3 changes: 1 addition & 2 deletions src/app/pages/staging/index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import './stylesheet.scss';
import { useState, useEffect } from '@wordpress/element';
import apiFetch from '@wordpress/api-fetch';
import classnames from 'classnames';
import { NewfoldRuntime } from '@newfold-labs/wp-module-runtime';
import { useNotification } from 'App/components/notifications';
// component sourced from staging module
Expand Down Expand Up @@ -127,7 +126,7 @@ const Staging = () => {
// methods to pass to module
const moduleMethods = {
apiFetch,
classnames,
classNames,
useState,
useEffect,
NewfoldRuntime,
Expand Down

0 comments on commit ccb3b41

Please sign in to comment.