Skip to content

Commit

Permalink
CSS and Styling Fixes (#4)
Browse files Browse the repository at this point in the history
* CSS fix

* Minor style changes

* Version Bump
  • Loading branch information
ianvexler authored Feb 12, 2024
1 parent c5507cf commit ac0eee6
Show file tree
Hide file tree
Showing 9 changed files with 52 additions and 13 deletions.
49 changes: 45 additions & 4 deletions example/pages/HomePage.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,51 @@
import { Title } from '@the-curve-consulting/texmo-react-components';
import { InfoTile, Title } from '@the-curve-consulting/texmo-react-components';
import { Row, Col } from 'react-bootstrap';

const HomePage = () => {
return (
<div className='mt-5'>
<Title text='Home Page'/>
</div>
<>
<Row className="my-5">
<Title text='Dashboard'/>
</Row>

<Row className="g-4">
<Col xl={6}>
<InfoTile icon='calendar-check'>
<InfoTile.Title title='My Work Requests'/>

<InfoTile.Item text='Due in the next 24 hours' value={0} />
<InfoTile.Item text='Overdue' theme='danger' value={1} />
<InfoTile.Item text='Open Requests' value={1} />
</InfoTile>
</Col>
<Col xl={6}>
<InfoTile icon='clipboard-check'>
<InfoTile.Title title='My Work Requests'/>

<InfoTile.Item text='Due in the next 24 hours' value={0} />
<InfoTile.Item text='Overdue' theme='danger' value={1} />
<InfoTile.Item text='Open Requests' value={1} />
</InfoTile>
</Col>

<Col xl={6}>
<InfoTile icon='person-vcard'>
<InfoTile.Title title={'My Approvals'}/>

<InfoTile.Item text='Active' value={0} />
</InfoTile>
</Col>

<Col xl={6}>
<InfoTile icon='diagram-2'>
<InfoTile.Title title={'My Work Requests'}/>

<InfoTile.Item text='Active' value={0} />
<InfoTile.Item text='Drafts' theme='info' value={0} />
</InfoTile>
</Col>
</Row>
</>
)
}

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"type": "git",
"url": "https://github.com/the-curve-consulting/texmo-react-components.git"
},
"version": "0.1.0",
"version": "0.2.0",
"description": "",
"main": "dist/index.min.js",
"module": "dist/index.es.js",
Expand Down
2 changes: 1 addition & 1 deletion rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ module.exports = {
plugins: [
external(),
postcss({
modules: true,
modules: false,
extract: true,
}),
// Allow json resolution
Expand Down
4 changes: 2 additions & 2 deletions scss/App.scss
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ h1 {
}

.nav-link.active {
background-color: var(--texmo-bg-secondary);
color: var(--texmo-text-color);
background-color: var(--texmo-bg-secondary) !important;
color: var(--texmo-text-color) !important;
}
}

Expand Down
1 change: 0 additions & 1 deletion scss/texmo-react-components.scss
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,3 @@
@import '../src/components/button/Button.scss';
@import '../src/components/title/Title.scss';
@import '../src/components/card/Card.scss';
@import '../src/components/form/components/FormRichText.scss';
1 change: 0 additions & 1 deletion src/components/form/components/FormRichText.scss

This file was deleted.

2 changes: 1 addition & 1 deletion src/components/infoTile/InfoTile.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ const InfoTile = ({ icon, children }: InfoTileProps) => {
<i className={`bi bi-${icon}`} style={{ fontSize: '4rem' }}></i>
</div>
</Col>
<Col className="py-4">
<Col className="py-4 me-4">
<Card.Body>{children}</Card.Body>
</Col>
</Row>
Expand Down
2 changes: 1 addition & 1 deletion src/components/infoTile/components/InfoTileItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ const InfoTileItem = ({
<CardText>
<span className="d-flex mb-3 justify-content-between">
{text}
<span className={`badge text-bg-${theme} p-2`}>{value}</span>
<span className={`badge bg-${theme} p-2`}>{value}</span>
</span>
</CardText>
);
Expand Down
2 changes: 1 addition & 1 deletion src/components/title/Title.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export interface TitleProps extends React.HTMLProps<HTMLHeadingElement> {

const Title = ({ text, ...rest }: TitleProps) => {
return (
<h1 className="title" {...rest}>
<h1 className="fw-bold" {...rest}>
{text}
</h1>
);
Expand Down

0 comments on commit ac0eee6

Please sign in to comment.