Skip to content

Commit 95adc8a

Browse files
committed
Add MVS example on index.html
1 parent 514efce commit 95adc8a

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

index.html

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -210,10 +210,16 @@ <h3>Extensions</h3>
210210
<div class="controlBox">
211211
<h4>Interaction extension</h4>
212212
<button onclick="PDBeMolstarPlugin.extensions.Interactions.loadInteractions_example(viewerInstance)">Show interactions (1hda)</button>
213-
<!-- <button onclick="PDBeMolstarPlugin.extensions.Interactions.loadInteractionsFromApi(viewerInstance, { pdbId: '1cbs', authAsymId: 'A', authSeqId: 200 })">Show interactions from API (1cbs)</button>
214-
<button onclick="PDBeMolstarPlugin.extensions.Interactions.loadInteractionsFromApi(viewerInstance, { pdbId: '1tqn', authAsymId: 'A', authSeqId: 508 })">Show interactions from API (1tqn)</button> -->
215-
<button onclick="PDBeMolstarPlugin.extensions.Interactions.loadInteractionsFromApi(viewerInstance, { pdbId: '1hda', authAsymId: 'C', authSeqId: 143 })">Show interactions from API (1hda)</button>
216213
<button onclick="PDBeMolstarPlugin.extensions.Interactions.clearInteractions(viewerInstance)">Clear</button>
214+
215+
<h4>MolViewSpec</h4>
216+
<button onclick="
217+
const builder = PDBeMolstarPlugin.extensions.MVS.MVSData.createBuilder();
218+
builder.canvas({ background_color: '#110044' }).download({ url: 'https:/\/www.ebi.ac.uk/pdbe/entry-files/download/2e2n.bcif' }).parse({ format: 'bcif' }).modelStructure().component().representation().color({ color: '#adb0e6', selector: { label_asym_id: 'A' } });
219+
const state = builder.getState({ description: 'Example MVS state' });
220+
PDBeMolstarPlugin.extensions.MVS.loadMVS(viewerInstance.plugin, state);">
221+
Load MVS
222+
</button>
217223
</div>
218224

219225
<div>

0 commit comments

Comments
 (0)