Skip to content

Commit

Permalink
Apply Prettier
Browse files Browse the repository at this point in the history
  • Loading branch information
ulasturann committed Jul 4, 2023
1 parent 8c458be commit 92d7730
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 42 deletions.
4 changes: 2 additions & 2 deletions components/lib/componentbase/ComponentBase.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ export const ComponentBase = {
},
context: undefined,
classes: {},
styles: "",
styles: '',
extend: (props = {}) => {
const css = props.css;
const defaultProps = { ...props.defaultProps, ...ComponentBase.defaultProps };
Expand Down Expand Up @@ -92,7 +92,7 @@ export const ComponentBase = {
}

return undefined;
}
};

return { ptm, ptmo, sx, cx };
};
Expand Down
4 changes: 2 additions & 2 deletions components/lib/hooks/useStyle.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { useEffect, useRef, useState } from 'react';
import { DomHandler, ObjectUtils } from "../utils/Utils";
import { DomHandler, ObjectUtils } from '../utils/Utils';

let _id = 0;

Expand Down Expand Up @@ -56,4 +56,4 @@ export const useStyle = (css = {}, options = {}) => {
load,
isLoaded
};
}
};
74 changes: 36 additions & 38 deletions components/lib/panel/PanelBase.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,44 +2,42 @@ import { ComponentBase } from '../componentbase/ComponentBase';
import { classNames } from '../utils/Utils';

export const PanelBase = ComponentBase.extend({
defaultProps: {
__TYPE: 'Panel',
id: null,
header: null,
headerTemplate: null,
footer: null,
footerTemplate: null,
toggleable: null,
style: null,
className: null,
collapsed: null,
expandIcon: null,
collapseIcon: null,
icons: null,
transitionOptions: null,
onExpand: null,
onCollapse: null,
onToggle: null,
children: undefined
},
css: {
classes: {
root: ({ props }) => classNames(
'p-panel p-component',
{
'p-panel-toggleable': props.toggleable
}
),
header: 'p-panel-header',
title: 'p-panel-title',
icons: 'p-panel-icons',
toggler: 'p-panel-header-icon p-panel-toggler p-link',
togglerIcon: 'p-panel-header-icon p-panel-toggler p-link',
toggleableContent: 'p-toggleable-content',
content: 'p-panel-content',
footer: 'p-panel-footer'
defaultProps: {
__TYPE: 'Panel',
id: null,
header: null,
headerTemplate: null,
footer: null,
footerTemplate: null,
toggleable: null,
style: null,
className: null,
collapsed: null,
expandIcon: null,
collapseIcon: null,
icons: null,
transitionOptions: null,
onExpand: null,
onCollapse: null,
onToggle: null,
children: undefined
},
styles: `
css: {
classes: {
root: ({ props }) =>
classNames('p-panel p-component', {
'p-panel-toggleable': props.toggleable
}),
header: 'p-panel-header',
title: 'p-panel-title',
icons: 'p-panel-icons',
toggler: 'p-panel-header-icon p-panel-toggler p-link',
togglerIcon: 'p-panel-header-icon p-panel-toggler p-link',
toggleableContent: 'p-toggleable-content',
content: 'p-panel-content',
footer: 'p-panel-footer'
},
styles: `
.p-panel-header {
display: flex;
justify-content: space-between;
Expand All @@ -60,5 +58,5 @@ export const PanelBase = ComponentBase.extend({
position: relative;
}
`
}
}
});

0 comments on commit 92d7730

Please sign in to comment.