tycho-components 0.4.4 → 0.4.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -15,7 +15,8 @@ export default function HeaderApps({ freeAccess }) {
15
15
  const { hasLexiconAccess, hasParserAccess, isAdminOfAnyCorpus } = useLoggedUtils();
16
16
  const [open, setOpen] = useState(false);
17
17
  const goto = (app, blank) => {
18
- const url = hasCorpus()
18
+ const shouldAppendCorpusUid = app.appendCorpusUid !== false;
19
+ const url = hasCorpus() && shouldAppendCorpusUid
19
20
  ? `/${app.code}/${getCorpus().uid}`
20
21
  : `/${app.code}`;
21
22
  if (blank) {
@@ -8,6 +8,7 @@ type App = {
8
8
  lexicon?: boolean;
9
9
  parser?: boolean;
10
10
  external?: string;
11
+ appendCorpusUid?: boolean;
11
12
  };
12
13
  export declare const AvailableApps: App[];
13
14
  export default App;
@@ -24,6 +24,7 @@ export const AvailableApps = [
24
24
  visibility: null,
25
25
  desktop: true,
26
26
  parser: true,
27
+ appendCorpusUid: false,
27
28
  },
28
29
  {
29
30
  code: 'io',
@@ -37,6 +38,7 @@ export const AvailableApps = [
37
38
  visibility: null,
38
39
  desktop: false,
39
40
  lexicon: true,
41
+ appendCorpusUid: false,
40
42
  },
41
43
  {
42
44
  code: 'search',
@@ -49,17 +51,20 @@ export const AvailableApps = [
49
51
  icon: 'news',
50
52
  visibility: 'public',
51
53
  desktop: false,
54
+ appendCorpusUid: false,
52
55
  },
53
56
  {
54
57
  code: 'synviewer',
55
58
  icon: 'graph_4',
56
59
  visibility: 'public',
57
60
  desktop: false,
61
+ appendCorpusUid: false,
58
62
  },
59
63
  {
60
64
  code: 'psd-reindexer',
61
65
  icon: '123',
62
66
  visibility: 'public',
63
67
  desktop: false,
68
+ appendCorpusUid: false,
64
69
  },
65
70
  ];
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "tycho-components",
3
3
  "private": false,
4
- "version": "0.4.4",
4
+ "version": "0.4.5",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
7
7
  "exports": {