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

Agrim/dapi544/quill UI #26

Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
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
4 changes: 3 additions & 1 deletion jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ module.exports = {
'^.+\\.mjs$': 'babel-jest',
},
transformIgnorePatterns: [
'node_modules/(?!(@docusaurus|swiper|ssr-window|dom7)|@theme|@deriv/quill-design)',
'node_modules/(?!(@docusaurus|swiper|ssr-window|dom7)|@theme|@deriv-com/quill-ui)',
],
moduleNameMapper: {
'@theme/(.*)': '@docusaurus/theme-classic/src/theme/$1',
Expand All @@ -30,7 +30,9 @@ module.exports = {
'@docusaurus/plugin-content-docs/client': '@docusaurus/plugin-content-docs/src/client/index.ts',
'@site/(.*)': '<rootDir>/$1',
'\\.(css|scss|sass|less)$': 'identity-obj-proxy',
'@deriv-com/quill-ui': 'node_modules/@deriv-com/quill-ui/dist/main.js',
},

moduleFileExtensions: ['js', 'jsx', 'ts', 'tsx', 'mjs', 'json'],
rootDir: '.',
roots: ['<rootDir>'],
Expand Down
68 changes: 63 additions & 5 deletions package-lock.json

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

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
"format": "prettier --write 'src/**/*.{js,jsx,ts,tsx,md,json}' --config ./.prettierrc"
},
"dependencies": {
"@deriv-com/quill-ui": "^1.9.11",
"@deriv/deriv-api": "^1.0.11",
"@deriv/quill-design": "^1.2.18",
"@deriv/quill-icons": "^1.21.3",
Expand Down
6 changes: 3 additions & 3 deletions src/components/SwipeableBottomSheet/index.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React, { useEffect, useRef } from 'react';
import { useDrag } from '@use-gesture/react';
import { a, useSpring, config } from '@react-spring/web';
import { Button } from '@deriv/quill-design';
import { Button } from '@deriv-com/quill-ui';
import './swipeable-bottom-sheet.scss';

type SwipeableBottomSheetProps = {
Expand Down Expand Up @@ -88,7 +88,7 @@ const SwipeableBottomSheet: React.FC<SwipeableBottomSheetProps> = ({
<div className='action_sheet__body__footer'>
{primary_action && (
<Button
colorStyle='black'
color='black'
size='md'
variant='primary'
onClick={primary_action.onClick}
Expand All @@ -98,7 +98,7 @@ const SwipeableBottomSheet: React.FC<SwipeableBottomSheetProps> = ({
)}
{secondary_action && (
<Button
colorStyle='black'
color='black'
size='md'
variant='secondary'
onClick={secondary_action.onClick}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import { Heading, Text } from '@deriv/quill-design';
import { Heading, Text } from '@deriv-com/quill-ui';
import './app-dashboard-container.scss';

const AppDashboardContainer: React.FC = ({ children }) => {
Expand Down
10 changes: 2 additions & 8 deletions src/features/dashboard/components/AppRegister/index.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import { Button, TextField } from '@deriv/quill-design';
import { Button, TextField } from '@deriv-com/quill-ui';
import { useForm } from 'react-hook-form';
import { yupResolver } from '@hookform/resolvers/yup';
import './app-register.scss';
Expand Down Expand Up @@ -74,13 +74,7 @@ const AppRegister: React.FC<TAppRegisterProps> = ({ submit }) => {
/>
</div>
<div className='app_register_container__fields__button'>
<Button
colorStyle='coral'
size='md'
variant='primary'
role='submit'
disabled={has_error}
>
<Button color='coral' size='md' variant='primary' role='submit' disabled={has_error}>
Register now
</Button>
</div>
Expand Down
6 changes: 3 additions & 3 deletions src/features/dashboard/components/AppsTable/index.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { ApplicationObject } from '@deriv/api-types';
import React, { HTMLAttributes, useCallback, useState } from 'react';
import { Cell, Column } from 'react-table';
import { Button, Heading, Text } from '@deriv/quill-design';
import { Button, Heading, Text } from '@deriv-com/quill-ui';
import { LabelPairedCirclePlusMdRegularIcon } from '@deriv/quill-icons';

import useAppManager from '@site/src/hooks/useAppManager';
Expand Down Expand Up @@ -73,12 +73,12 @@ const AppsTableHeader: React.FC<{ is_desktop: boolean }> = ({ is_desktop }) => {
</Text>
</div>
<Button
colorStyle='coral'
color='coral'
size='md'
variant='primary'
role='submit'
iconPosition='start'
icon={LabelPairedCirclePlusMdRegularIcon}
icon={<LabelPairedCirclePlusMdRegularIcon />}
className='apps_table__header__button'
onClick={() => {
updateCurrentTab('REGISTER_APP');
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React from 'react';
import useAppManager from '@site/src/hooks/useAppManager';
import SwipeableBottomSheet from '@site/src/components/SwipeableBottomSheet';
import { Heading } from '@deriv/quill-design';
import { Heading } from '@deriv-com/quill-ui';
import './app-register-success-modal.scss';

interface IAppRegisterSuccessModalProps {
Expand Down
4 changes: 2 additions & 2 deletions src/theme/Root.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import { ThemeProvider } from '@deriv/ui';
import { ThemeProvider } from '@deriv-com/quill-ui';
import type { ReactNode } from 'react';
import { TrackJS } from 'trackjs';
import siteConfig from '@generated/docusaurus.config';
Expand Down Expand Up @@ -30,7 +30,7 @@ export default function Root({ children }: TRootProps) {
<PlaygroundProvider>
<ApiTokenProvider>
<AppManagerContextProvider>
<ThemeProvider>{children}</ThemeProvider>
<ThemeProvider theme='light'>{children}</ThemeProvider>
</AppManagerContextProvider>
</ApiTokenProvider>
</PlaygroundProvider>
Expand Down