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

Revert "Set import paths correctly for PCUI React" #275

Merged
merged 1 commit into from
Dec 19, 2023
Merged
Show file tree
Hide file tree
Changes from all 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
2 changes: 1 addition & 1 deletion src/ui/components/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import {
SliderInput,
VectorInput,
NumericInput
} from '@playcanvas/pcui/react';
} from 'pcui';
import { Option } from '../../types';

export const Detail = (props: { label: string, value:string|number}) => {
Expand Down
2 changes: 1 addition & 1 deletion src/ui/errors.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import { InfoBox } from '@playcanvas/pcui/react';
import { InfoBox } from 'pcui';
import { ObserverData } from '../types';

// InfoBox that shows an error
Expand Down
2 changes: 1 addition & 1 deletion src/ui/index.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { Observer } from '@playcanvas/observer';
import React from 'react';
import ReactDOM from 'react-dom';
import { Container, Spinner } from '@playcanvas/pcui/react';
import { Container, Spinner } from 'pcui';

import { getAssetPath } from '../helpers';
import { ObserverData } from '../types';
Expand Down
2 changes: 1 addition & 1 deletion src/ui/left-panel/index.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import { Panel, Container, TreeViewItem, TreeView } from '@playcanvas/pcui/react';
import { Panel, Container, TreeViewItem, TreeView } from 'pcui';
import { HierarchyNode, SetProperty, ObserverData } from '../../types';

import { Detail, Select, Toggle, Vector } from '../components';
Expand Down
2 changes: 1 addition & 1 deletion src/ui/left-panel/morph-target-panel.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React from 'react';
import VisibilitySensor from 'react-visibility-sensor';
import { MorphTargetData, SetProperty, ObserverData } from '../../types';
import { Panel } from '@playcanvas/pcui/react';
import { Panel } from 'pcui';
import { MorphSlider } from '../components';

class MorphTargetPanel extends React.Component <{ morphs: ObserverData['morphs'], progress: number, setProperty: SetProperty }> {
Expand Down
2 changes: 1 addition & 1 deletion src/ui/load-controls.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React, { useRef, useState } from 'react';
import { Container, Label, Button, TextInput } from '@playcanvas/pcui/react';
import { Container, Label, Button, TextInput } from 'pcui';
import { getAssetPath } from '../helpers';

import { File, SetProperty } from '../types';
Expand Down
2 changes: 1 addition & 1 deletion src/ui/popup-panel/animation-controls.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import { Button } from '@playcanvas/pcui/react';
import { Button } from 'pcui';
import { SetProperty, ObserverData } from '../../types';

import { NakedSelect, NakedSlider } from '../components';
Expand Down
3 changes: 2 additions & 1 deletion src/ui/popup-panel/index.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import React from 'react';
import { Button } from '@playcanvas/pcui/react';
import { Observer } from '@playcanvas/observer';
import { Button } from 'pcui';
import { SetProperty, ObserverData } from '../../types';
import AnimationControls from './animation-controls';
import { CameraPanel, SkyboxPanel, LightPanel, DebugPanel, ViewPanel } from './panels';
Expand Down
2 changes: 1 addition & 1 deletion src/ui/popup-panel/panels.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import { Container, Button, Label, TextInput } from '@playcanvas/pcui/react';
import { Container, Button, Label, TextInput } from 'pcui';
import { SetProperty, ObserverData } from '../../types';
import { extract } from '../../helpers';
// @ts-ignore no type defs included
Expand Down
2 changes: 1 addition & 1 deletion src/ui/selected-node.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import { Container } from '@playcanvas/pcui/react';
import { Container } from 'pcui';
import { SetProperty, ObserverData } from '../types';

import { Vector, Detail } from './components';
Expand Down
1 change: 1 addition & 0 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
"noEmit": true,
"baseUrl": ".",
"paths": {
"pcui": ["node_modules/@playcanvas/pcui"],
"playcanvas-extras": ["node_modules/playcanvas/build/playcanvas-extras.mjs"]
}
},
Expand Down