-
Notifications
You must be signed in to change notification settings - Fork 438
Expand file tree
/
Copy pathApp.tsx
More file actions
116 lines (101 loc) · 3.75 KB
/
Copy pathApp.tsx
File metadata and controls
116 lines (101 loc) · 3.75 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
/* eslint-disable react/react-in-jsx-scope */
import { version } from '@docsearch/react';
import { DocSearchSidepanel } from '@docsearch/react/sidepanel';
import type { JSX } from 'react';
import './App.css';
import '@docsearch/css/dist/style.css';
import '@docsearch/css/dist/sidepanel.css';
import Basic from './examples/basic';
import BasicAskAI from './examples/basic-askai';
import Composable from './examples/composable';
import Default from './examples/default';
import DynamicImportModal from './examples/dynamic-import-modal';
import BasicHybrid from './examples/hybrid';
import MultiIndex from './examples/multi-index';
import WHitComponent from './examples/w-hit-component';
import WTransformItems from './examples/w-hit-transformItems';
import WResultsFooter from './examples/w-results-footer';
function App(): JSX.Element {
return (
<div className="body-container">
<div className="app-container">
<header className="app-header">
<h1 className="app-title">DocSearch v{version}</h1>
<p className="app-subtitle">Experience the power of intelligent documentation search</p>
</header>
<main>
<section className="demo-section">
<p className="section-description">default</p>
<div className="default-wrapper">
<Default />
</div>
</section>
<section className="demo-section">
<p className="section-description">basic search functionality</p>
<div className="search-wrapper">
<Basic />
</div>
</section>
<section className="demo-section">
<p className="section-description">search with ask ai integration</p>
<div className="search-wrapper">
<BasicAskAI />
</div>
</section>
<section className="demo-section">
<p className="section-description">custom hit rendering</p>
<div className="search-wrapper">
<WHitComponent />
</div>
</section>
<section className="demo-section">
<p className="section-description">transform items before rendering</p>
<div className="search-wrapper">
<WTransformItems />
</div>
</section>
<section className="demo-section">
<p className="section-description">multi index search</p>
<div className="search-wrapper">
<MultiIndex />
</div>
</section>
<section className="demo-section">
<p className="section-description">composable</p>
<div className="search-wrapper">
<Composable />
</div>
</section>
<section className="demo-section">
<p className="section-description">dynamically imported modal</p>
<div className="search-wrapper">
<DynamicImportModal />
</div>
</section>
<section className="demo-section">
<p className="section-description">results footer component</p>
<div className="search-wrapper">
<WResultsFooter />
</div>
</section>
<section className="demo-section">
<p className="section-description">sidepanel hybrid</p>
<div className="search-wrapper">
<BasicHybrid />
</div>
</section>
</main>
</div>
<DocSearchSidepanel
assistantId="ccdec697-e3fe-465b-a1c3-657e7bf18aef"
indexName="docsearch"
appId="PMZUYBQDAK"
apiKey="24b09689d5b4223813d9b8e48563c8f6"
panel={{
suggestedQuestions: true,
}}
/>
</div>
);
}
export default App;