fix: server/client parity
This commit is contained in:
parent
7aa648fc9d
commit
4fbbbbeac4
|
@ -17,8 +17,6 @@
|
|||
"files": [
|
||||
"assets",
|
||||
"build",
|
||||
"client.js",
|
||||
"client.js.map",
|
||||
"index.css",
|
||||
"index.css.map",
|
||||
"index.js",
|
||||
|
|
|
@ -1,9 +0,0 @@
|
|||
import {Hooks} from '@flecks/core';
|
||||
|
||||
import Persea from './components/persea';
|
||||
|
||||
export default {
|
||||
[Hooks]: {
|
||||
'@flecks/react.roots': () => Persea,
|
||||
},
|
||||
};
|
|
@ -20,6 +20,10 @@ import {
|
|||
import OrganizationActions from './actions';
|
||||
import './index.scss';
|
||||
|
||||
const normalizeDisplayName = (displayName) => (
|
||||
displayName.startsWith('HotExported') ? displayName.slice(11) : displayName
|
||||
);
|
||||
|
||||
const Organization = ({
|
||||
className,
|
||||
label,
|
||||
|
@ -29,11 +33,7 @@ const Organization = ({
|
|||
const dispatch = useDispatch();
|
||||
const flecks = useFlecks();
|
||||
const location = useLocation();
|
||||
const [collapsed, __setCollapsed] = useState(JSON.parse(window.localStorage['@persea/core/explorer'] || '{}'));
|
||||
const setCollapsed = (next) => {
|
||||
window.localStorage['@persea/core/explorer'] = JSON.stringify(next);
|
||||
__setCollapsed(next);
|
||||
};
|
||||
const [collapsed, setCollapsed] = useState({});
|
||||
const treeFromResourcePath = (tree, uuid, [isFile, resourcePath]) => {
|
||||
const parts = resourcePath.split('/');
|
||||
parts.shift();
|
||||
|
@ -100,7 +100,7 @@ const Organization = ({
|
|||
.Component;
|
||||
return (
|
||||
<div className="label inline">
|
||||
{!nodes && <div className={`icon ${displayName}`} />}
|
||||
{!nodes && <div className={`icon ${normalizeDisplayName(displayName)}`} />}
|
||||
<span className="text">{label}</span>
|
||||
{value === uuid && (
|
||||
<OrganizationActions
|
||||
|
|
|
@ -1,12 +1,14 @@
|
|||
import {patchJsonResource} from '@avocado/resource-persea';
|
||||
import {Hooks} from '@flecks/core';
|
||||
|
||||
import Persea from './components/persea';
|
||||
import {projects} from './state';
|
||||
|
||||
export * from './state';
|
||||
|
||||
export default {
|
||||
[Hooks]: {
|
||||
'@flecks/react.roots': () => Persea,
|
||||
'@flecks/redux.effects': (flecks) => {
|
||||
const withSocket = (fn) => (...args) => fn(...args.concat(flecks.get('$flecks/socket.socket')));
|
||||
return {
|
||||
|
|
|
@ -22,9 +22,6 @@ export default {
|
|||
resources(req, res, next);
|
||||
return;
|
||||
}
|
||||
if (req.url.startsWith('/project')) {
|
||||
req.url = '/';
|
||||
}
|
||||
next();
|
||||
},
|
||||
'@flecks/socket.packets.decorate': (
|
||||
|
|
Loading…
Reference in New Issue
Block a user