Version: 4.x
vime-control-spacer
Used to space controls out vertically/horizontally. Under the hood it's simply flex: 1
.
Visual#
Usage#
- HTML
- React
- Vue
- Svelte
- Stencil
- Angular
<vime-player>
<!-- ... -->
<vime-ui>
<!-- ... -->
<vime-controls full-width>
<vime-playback-control></vime-playback-control>
<vime-volume-control></vime-volume-control>
<vime-control-spacer></vime-control-spacer>
<vime-fullscreen-control></vime-fullscreen-control>
</vime-controls>
</vime-ui>
</vime-player>
import React from 'react';
import {
VimePlayer,
VimeUi,
VimeControls,
VimePlaybackControl,
VimeVolumeControl,
VimeControlSpacer,
VimeFullscreenControl,
} from '@vime/react';
function Example() {
return (
<VimePlayer>
{/* ... */}
<VimeUi>
<VimeControls fullWidth>
<VimePlaybackControl />
<VimeVolumeControl />
<VimeControlSpacer />
<VimeFullscreenControl />
</VimeControls>
</VimeUi>
</VimePlayer>
);
}
example.vue
<template>
<VimePlayer>
<!-- ... -->
<VimeUi>
<VimeControls>
<VimePlaybackControl />
<VimeVolumeControl />
<VimeControlSpacer />
<VimeFullscreenControl />
</VimeControls>
</VimeUi>
</VimePlayer>
</template>
<script>
import {
VimePlayer,
VimeUi,
VimeControls,
VimePlaybackControl,
VimeVolumeControl,
VimeControlSpacer,
VimeFullscreenControl,
} from '@vime/vue';
export default {
components: {
VimePlayer,
VimeUi,
VimeControls,
VimePlaybackControl,
VimeVolumeControl,
VimeControlSpacer,
VimeFullscreenControl,
},
};
</script>
example.svelte
<VimePlayer>
<!-- ... -->
<VimeUi>
<!-- ... -->
<VimeControls fullWidth>
<VimePlaybackControl />
<VimeVolumeControl />
<VimeControlSpacer />
<VimeFullscreenControl />
</VimeControls>
</VimeUi>
</VimePlayer>
<script lang="ts">
import {
VimePlayer,
VimeUi,
VimeControls,
VimePlaybackControl,
VimeVolumeControl,
VimeControlSpacer,
VimeFullscreenControl,
} from '@vime/svelte';
</script>
class Example {
render() {
return (
<vime-player>
{/* ... */}
<vime-ui>
{/* ... */}
<vime-controls fullWidth>
<vime-playback-control />
<vime-volume-control />
<vime-control-spacer />
<vime-fullscreen-control />
</vime-controls>
</vime-ui>
</vime-player>
);
}
}
example.html
<vime-player>
<!-- ... -->
<vime-ui>
<!-- ... -->
<vime-controls full-width>
<vime-playback-control></vime-playback-control>
<vime-volume-control></vime-volume-control>
<vime-control-spacer></vime-control-spacer>
<vime-fullscreen-control></vime-fullscreen-control>
</vime-controls>
</vime-ui>
</vime-player>
Dependencies#
Used by#
Graph#
graph TD;
vime-default-controls --> vime-control-spacer
style vime-control-spacer fill:#f9f,stroke:#333,stroke-width:4px
Built with StencilJS