Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
B
Bielefeld-CeBiTec
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Model registry
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
2024 Competition
Bielefeld-CeBiTec
Commits
dafdb9d4
Commit
dafdb9d4
authored
6 months ago
by
Asal Sahami Moghaddam
Browse files
Options
Downloads
Patches
Plain Diff
fanzor
parent
df25d7ff
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/components/Fanzorviewer.tsx
+6
-6
6 additions, 6 deletions
src/components/Fanzorviewer.tsx
src/contents/description.tsx
+1
-0
1 addition, 0 deletions
src/contents/description.tsx
src/contents/engineering.tsx
+1
-0
1 addition, 0 deletions
src/contents/engineering.tsx
with
8 additions
and
6 deletions
src/components/Fanzorviewer.tsx
+
6
−
6
View file @
dafdb9d4
import
React
,
{
useEffect
}
from
'
react
'
;
import
React
,
{
useRef
,
useEffect
}
from
'
react
'
;
import
*
as
THREE
from
'
three
'
;
export
const
ProteinViewer
:
React
.
FC
=
()
=>
{
...
...
@@ -9,9 +9,9 @@ export const ProteinViewer: React.FC = () => {
const
camera
=
new
THREE
.
PerspectiveCamera
(
75
,
1
,
0.1
,
1000
);
// Adjust aspect ratio if needed
const
renderer
=
new
THREE
.
WebGLRenderer
({
antialias
:
true
});
renderer
.
setSize
(
2
00
,
2
00
);
renderer
.
setSize
(
1
00
,
1
00
);
// Set a smaller size
// Append the renderer to the div container instead of body
if
(
viewerRef
.
current
)
{
viewerRef
.
current
.
appendChild
(
renderer
.
domElement
);
}
...
...
@@ -20,7 +20,7 @@ export const ProteinViewer: React.FC = () => {
light
.
position
.
set
(
0
,
1
,
2
);
scene
.
add
(
light
);
camera
.
position
.
z
=
5
;
camera
.
position
.
z
=
10
;
// Render loop
const
animate
=
()
=>
{
...
...
@@ -41,8 +41,8 @@ export const ProteinViewer: React.FC = () => {
<
div
ref
=
{
viewerRef
}
style
=
{
{
width
:
'
4
00px
'
,
//
Customize the
width
height
:
'
4
00px
'
,
//
Customize the
height
width
:
'
1
00px
'
,
//
Smaller
width
height
:
'
1
00px
'
,
//
Smaller
height
margin
:
'
0 auto
'
,
// Center it if you want
border
:
'
1px solid #ddd
'
,
// Optional: border around the viewer
}
}
...
...
This diff is collapsed.
Click to expand it.
src/contents/description.tsx
+
1
−
0
View file @
dafdb9d4
...
...
@@ -63,6 +63,7 @@ export function Description() {
</
div
>
<
div
className
=
"col"
>
<
p
>
Text about CFTR
<
LoremMedium
/></
p
>
<
img
src
=
"https://static.igem.wiki/teams/5247/fanzor/cftr.gif"
></
img
>
</
div
>
</
div
>
</
Subesction
>
...
...
This diff is collapsed.
Click to expand it.
src/contents/engineering.tsx
+
1
−
0
View file @
dafdb9d4
...
...
@@ -169,6 +169,7 @@ export function Engineering() {
<
H3
id
=
"Nikase"
text
=
"Nikase"
></
H3
>
<
p
><
LoremShort
></
LoremShort
></
p
>
<
img
src
=
"https://static.igem.wiki/teams/5247/fanzor/movie4-ezgif-com-video-to-gif-converter.gif"
></
img
>
<
img
src
=
"https://static.igem.wiki/teams/5247/fanzor/movie5-ezgif-com-video-to-gif-converter-2.gif"
></
img
>
</
div
>
<
div
className
=
"box"
>
<
p
id
=
"nik1"
>
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment