Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
Molstar
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Michal Malý
Molstar
Commits
fc90ee91
Commit
fc90ee91
authored
6 years ago
by
David Sehnal
Browse files
Options
Downloads
Patches
Plain Diff
mol-state: isLocked transform prop support
parent
ac637b67
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/mol-plugin/ui/state-tree.tsx
+3
-5
3 additions, 5 deletions
src/mol-plugin/ui/state-tree.tsx
src/mol-state/transform.ts
+3
-1
3 additions, 1 deletion
src/mol-state/transform.ts
with
6 additions
and
6 deletions
src/mol-plugin/ui/state-tree.tsx
+
3
−
5
View file @
fc90ee91
...
...
@@ -177,10 +177,6 @@ class StateTreeNodeLabel extends PluginComponent<{ nodeRef: string, state: State
const
children
=
this
.
props
.
state
.
tree
.
children
.
get
(
this
.
props
.
nodeRef
);
const
cellState
=
this
.
props
.
state
.
cellStates
.
get
(
this
.
props
.
nodeRef
);
const
remove
=
<
button
onClick
=
{
this
.
remove
}
className
=
'msp-btn msp-btn-link msp-tree-remove-button'
>
<
span
className
=
'msp-icon msp-icon-remove'
/>
</
button
>;
const
visibility
=
<
button
onClick
=
{
this
.
toggleVisible
}
className
=
{
`msp-btn msp-btn-link msp-tree-visibility
${
cellState
.
isHidden
?
'
msp-tree-visibility-hidden
'
:
''
}
`
}
>
<
span
className
=
'msp-icon msp-icon-visual-visibility'
/>
</
button
>;
...
...
@@ -190,7 +186,9 @@ class StateTreeNodeLabel extends PluginComponent<{ nodeRef: string, state: State
{
children
.
size
>
0
&&
<
button
onClick
=
{
this
.
toggleExpanded
}
className
=
'msp-btn msp-btn-link msp-tree-toggle-exp-button'
>
<
span
className
=
{
`msp-icon msp-icon-
${
cellState
.
isCollapsed
?
'
expand
'
:
'
collapse
'
}
`
}
/>
</
button
>
}
{
remove
}{
visibility
}
{
!
cell
.
transform
.
props
.
isLocked
&&
<
button
onClick
=
{
this
.
remove
}
className
=
'msp-btn msp-btn-link msp-tree-remove-button'
>
<
span
className
=
'msp-icon msp-icon-remove'
/>
</
button
>
}{
visibility
}
</
div
>
}
}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
src/mol-state/transform.ts
+
3
−
1
View file @
fc90ee91
...
...
@@ -25,7 +25,9 @@ export namespace Transform {
export
interface
Props
{
tag
?:
string
isGhost
?:
boolean
,
isBinding
?:
boolean
isBinding
?:
boolean
,
// determine if the corresponding cell can be deleted by the user.
isLocked
?:
boolean
}
export
interface
Options
{
...
...
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