Current section
Files
Jump to
Current section
Files
lib/components/spin.ex
defmodule LiveAntd.Components.Spin do
@moduledoc """
A spinner for displaying loading state of a page or a section.
## API
* [ ] `delay`: Specifies a delay in milliseconds for loading state (prevent flush) number (milliseconds) -
* [ ] `indicator`: React node of the spinning indicator
* [ ] `size`: The size of Spin, options: small, default and large string default
* [ ] `spinning`: Whether Spin is spinning boolean true
* [ ] `tip`: Customize description content when Spin has children string -
* [ ] `wrapperClassName`: The className of wrapper when Spin has children string
## Example
<Spin indicator={{@antIcon}} />
"""
use Surface.Component
def render(assigns) do
~H"""
<div class="ant-spin ant-spin-spinning">
<span class="ant-spin-dot ant-spin-dot-spin">
<i class="ant-spin-dot-item"></i>
<i class="ant-spin-dot-item"></i>
<i class="ant-spin-dot-item"></i>
<i class="ant-spin-dot-item"></i>
</span>
</div>
"""
end
end