FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
dstack/docs/src/components/Flowchart.tsx at main · dstack-js/dstack · GitHub
This repository was archived by the owner on Nov 23, 2022. It is now read-only.
dstack-js
/
dstack
Public archive
Uh oh!
There was an error while loading.
Please reload this page
.
Notifications
You must be signed in to change notification settings
Fork
4
Star
20
Code
Issues
1
Pull requests
13
Discussions
Actions
Security and quality
0
Insights
Additional navigation options
Code
Issues
Pull requests
Discussions
Actions
Security and quality
Insights
Expand file tree
Breadcrumbs
dstack
/
docs
/
src
/
components
/
Flowchart.tsx
Copy path
More file actions
More file actions
Latest commit
History
History
History
35 lines (32 loc) · 795 Bytes
Breadcrumbs
dstack
/
docs
/
src
/
components
/
Flowchart.tsx
Copy path
File metadata and controls
35 lines (32 loc) · 795 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
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
import
React
from
'react'
;
import
ReactFlow
,
{
Controls
,
Background
,
BackgroundVariant
,
OnLoadFunc
}
from
'react-flow-renderer'
;
const
onLoad
:
OnLoadFunc
=
(
flow
)
=>
{
flow
.
fitView
(
)
;
}
;
const
Flowchart
:
React
.
FC
<
any
>
=
(
{
elements
,
style
,
...
props
}
)
=>
(
<
div
style
=
{
{
height
:
425
,
background
:
'white'
,
borderRadius
:
'4px'
,
padding
:
'4px'
,
...
style
,
}
}
>
<
ReactFlow
elements
=
{
elements
}
//
@ts
-ignore
grid
=
{
true
}
nodesDraggable
=
{
false
}
onLoad
=
{
onLoad
}
nodesConnectable
=
{
false
}
elementsSelectable
=
{
false
}
{
...
props
}
>
<
Background
variant
=
{
BackgroundVariant
.
Dots
}
gap
=
{
10
}
size
=
{
0.5
}
/>
{
/* <MiniMap /> */
}
<
Controls
/>
</
ReactFlow
>
</
div
>
)
;
export
default
Flowchart
;
Back
|
FazBrowse Home
|
New Git URL