mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
24 lines
8.2 KiB
JavaScript
24 lines
8.2 KiB
JavaScript
import{o as a,a as t,y as n}from"./vue-libs.b44bc779.js";const d={class:"van-doc-markdown-body"},l=n(`<h1>Loading \u52A0\u8F7D</h1><div class="van-doc-card"><h3 id="jie-shao" tabindex="-1">\u4ECB\u7ECD</h3><p>\u52A0\u8F7D\u56FE\u6807\uFF0C\u7528\u4E8E\u8868\u793A\u52A0\u8F7D\u4E2D\u7684\u8FC7\u6E21\u72B6\u6001\u3002</p></div><div class="van-doc-card"><h3 id="yin-ru" tabindex="-1">\u5F15\u5165</h3><p>\u901A\u8FC7\u4EE5\u4E0B\u65B9\u5F0F\u6765\u5168\u5C40\u6CE8\u518C\u7EC4\u4EF6\uFF0C\u66F4\u591A\u6CE8\u518C\u65B9\u5F0F\u8BF7\u53C2\u8003<a href="#/zh-CN/advanced-usage#zu-jian-zhu-ce" target="_blank">\u7EC4\u4EF6\u6CE8\u518C</a>\u3002</p><pre><code class="language-js"><span class="hljs-keyword">import</span> { createApp } <span class="hljs-keyword">from</span> <span class="hljs-string">'vue'</span>;
|
|
<span class="hljs-keyword">import</span> { <span class="hljs-title class_">Loading</span> } <span class="hljs-keyword">from</span> <span class="hljs-string">'vant'</span>;
|
|
|
|
<span class="hljs-keyword">const</span> app = <span class="hljs-title function_">createApp</span>();
|
|
app.<span class="hljs-title function_">use</span>(<span class="hljs-title class_">Loading</span>);
|
|
</code></pre></div><h2 id="dai-ma-yan-shi" tabindex="-1">\u4EE3\u7801\u6F14\u793A</h2><div class="van-doc-card"><h3 id="jia-zai-lei-xing" tabindex="-1">\u52A0\u8F7D\u7C7B\u578B</h3><p>\u901A\u8FC7 <code>type</code> \u5C5E\u6027\u53EF\u4EE5\u8BBE\u7F6E\u52A0\u8F7D\u56FE\u6807\u7684\u7C7B\u578B\uFF0C\u9ED8\u8BA4\u4E3A <code>circular</code>\uFF0C\u53EF\u9009\u503C\u4E3A <code>spinner</code>\u3002</p><pre><code class="language-html"><span class="hljs-tag"><<span class="hljs-name">van-loading</span> /></span>
|
|
|
|
<span class="hljs-tag"><<span class="hljs-name">van-loading</span> <span class="hljs-attr">type</span>=<span class="hljs-string">"spinner"</span> /></span>
|
|
</code></pre></div><div class="van-doc-card"><h3 id="zi-ding-yi-yan-se" tabindex="-1">\u81EA\u5B9A\u4E49\u989C\u8272</h3><p>\u901A\u8FC7 <code>color</code> \u5C5E\u6027\u8BBE\u7F6E\u52A0\u8F7D\u56FE\u6807\u7684\u989C\u8272\u3002</p><pre><code class="language-html"><span class="hljs-tag"><<span class="hljs-name">van-loading</span> <span class="hljs-attr">color</span>=<span class="hljs-string">"#1989fa"</span> /></span>
|
|
|
|
<span class="hljs-tag"><<span class="hljs-name">van-loading</span> <span class="hljs-attr">type</span>=<span class="hljs-string">"spinner"</span> <span class="hljs-attr">color</span>=<span class="hljs-string">"#1989fa"</span> /></span>
|
|
</code></pre></div><div class="van-doc-card"><h3 id="zi-ding-yi-da-xiao" tabindex="-1">\u81EA\u5B9A\u4E49\u5927\u5C0F</h3><p>\u901A\u8FC7 <code>size</code> \u5C5E\u6027\u8BBE\u7F6E\u52A0\u8F7D\u56FE\u6807\u7684\u5927\u5C0F\uFF0C\u9ED8\u8BA4\u5355\u4F4D\u4E3A <code>px</code>\u3002</p><pre><code class="language-html"><span class="hljs-tag"><<span class="hljs-name">van-loading</span> <span class="hljs-attr">size</span>=<span class="hljs-string">"24"</span> /></span>
|
|
|
|
<span class="hljs-tag"><<span class="hljs-name">van-loading</span> <span class="hljs-attr">type</span>=<span class="hljs-string">"spinner"</span> <span class="hljs-attr">size</span>=<span class="hljs-string">"24px"</span> /></span>
|
|
</code></pre></div><div class="van-doc-card"><h3 id="jia-zai-wen-an" tabindex="-1">\u52A0\u8F7D\u6587\u6848</h3><p>\u53EF\u4EE5\u4F7F\u7528\u9ED8\u8BA4\u63D2\u69FD\u5728\u56FE\u6807\u7684\u53F3\u4FA7\u63D2\u5165\u52A0\u8F7D\u6587\u6848\u3002</p><pre><code class="language-html"><span class="hljs-tag"><<span class="hljs-name">van-loading</span> <span class="hljs-attr">size</span>=<span class="hljs-string">"24px"</span>></span>\u52A0\u8F7D\u4E2D...<span class="hljs-tag"></<span class="hljs-name">van-loading</span>></span>
|
|
</code></pre></div><div class="van-doc-card"><h3 id="chui-zhi-pai-lie" tabindex="-1">\u5782\u76F4\u6392\u5217</h3><p>\u8BBE\u7F6E <code>vertical</code> \u5C5E\u6027\u540E\uFF0C\u56FE\u6807\u548C\u6587\u6848\u4F1A\u5782\u76F4\u6392\u5217\u3002</p><pre><code class="language-html"><span class="hljs-tag"><<span class="hljs-name">van-loading</span> <span class="hljs-attr">size</span>=<span class="hljs-string">"24px"</span> <span class="hljs-attr">vertical</span>></span>\u52A0\u8F7D\u4E2D...<span class="hljs-tag"></<span class="hljs-name">van-loading</span>></span>
|
|
</code></pre></div><div class="van-doc-card"><h3 id="zi-ding-yi-wen-an-yan-se" tabindex="-1">\u81EA\u5B9A\u4E49\u6587\u6848\u989C\u8272</h3><p>\u901A\u8FC7 <code>color</code> \u6216\u8005 <code>text-color</code> \u5C5E\u6027\u8BBE\u7F6E\u52A0\u8F7D\u6587\u6848\u7684\u989C\u8272\u3002</p><pre><code class="language-html"><span class="hljs-comment"><!-- \u53EF\u4FEE\u6539\u6587\u6848\u548C\u52A0\u8F7D\u56FE\u6807\u7684\u989C\u8272 --></span>
|
|
<span class="hljs-tag"><<span class="hljs-name">van-loading</span> <span class="hljs-attr">color</span>=<span class="hljs-string">"#0094ff"</span> /></span>
|
|
|
|
<span class="hljs-comment"><!-- \u53EA\u4FEE\u6539\u6587\u6848\u989C\u8272 --></span>
|
|
<span class="hljs-tag"><<span class="hljs-name">van-loading</span> <span class="hljs-attr">text-color</span>=<span class="hljs-string">"#0094ff"</span> /></span>
|
|
</code></pre></div><h2 id="api" tabindex="-1">API</h2><div class="van-doc-card"><h3 id="props" tabindex="-1">Props</h3><table><thead><tr><th>\u53C2\u6570</th><th>\u8BF4\u660E</th><th>\u7C7B\u578B</th><th>\u9ED8\u8BA4\u503C</th></tr></thead><tbody><tr><td>color</td><td>\u989C\u8272</td><td><em>string</em></td><td><code>#c9c9c9</code></td></tr><tr><td>type</td><td>\u7C7B\u578B\uFF0C\u53EF\u9009\u503C\u4E3A <code>spinner</code></td><td><em>string</em></td><td><code>circular</code></td></tr><tr><td>size</td><td>\u52A0\u8F7D\u56FE\u6807\u5927\u5C0F\uFF0C\u9ED8\u8BA4\u5355\u4F4D\u4E3A <code>px</code></td><td><em>number | string</em></td><td><code>30px</code></td></tr><tr><td>text-size</td><td>\u6587\u5B57\u5927\u5C0F\uFF0C\u9ED8\u8BA4\u5355\u4F4D\u4E3A <code>px</code></td><td><em>number | string</em></td><td><code>14px</code></td></tr><tr><td>text-color</td><td>\u6587\u5B57\u989C\u8272</td><td><em>string</em></td><td><code>#c9c9c9</code></td></tr><tr><td>vertical</td><td>\u662F\u5426\u5782\u76F4\u6392\u5217\u56FE\u6807\u548C\u6587\u5B57\u5185\u5BB9</td><td><em>boolean</em></td><td><code>false</code></td></tr></tbody></table></div><div class="van-doc-card"><h3 id="slots" tabindex="-1">Slots</h3><table><thead><tr><th>\u540D\u79F0</th><th>\u8BF4\u660E</th></tr></thead><tbody><tr><td>default</td><td>\u52A0\u8F7D\u6587\u6848</td></tr></tbody></table></div><div class="van-doc-card"><h3 id="lei-xing-ding-yi" tabindex="-1">\u7C7B\u578B\u5B9A\u4E49</h3><p>\u7EC4\u4EF6\u5BFC\u51FA\u4EE5\u4E0B\u7C7B\u578B\u5B9A\u4E49\uFF1A</p><pre><code class="language-ts"><span class="hljs-keyword">import</span> <span class="hljs-keyword">type</span> { <span class="hljs-title class_">LoadingType</span>, <span class="hljs-title class_">LoadingProps</span> } <span class="hljs-keyword">from</span> <span class="hljs-string">'vant'</span>;
|
|
</code></pre></div><h2 id="zhu-ti-ding-zhi" tabindex="-1">\u4E3B\u9898\u5B9A\u5236</h2><div class="van-doc-card"><h3 id="yang-shi-bian-liang" tabindex="-1">\u6837\u5F0F\u53D8\u91CF</h3><p>\u7EC4\u4EF6\u63D0\u4F9B\u4E86\u4E0B\u5217 CSS \u53D8\u91CF\uFF0C\u53EF\u7528\u4E8E\u81EA\u5B9A\u4E49\u6837\u5F0F\uFF0C\u4F7F\u7528\u65B9\u6CD5\u8BF7\u53C2\u8003 <a href="#/zh-CN/config-provider" target="_blank">ConfigProvider \u7EC4\u4EF6</a>\u3002</p><table><thead><tr><th>\u540D\u79F0</th><th>\u9ED8\u8BA4\u503C</th><th>\u63CF\u8FF0</th></tr></thead><tbody><tr><td>--van-loading-text-color</td><td><em>var(--van-text-color-2)</em></td><td>-</td></tr><tr><td>--van-loading-text-font-size</td><td><em>var(--van-font-size-md)</em></td><td>-</td></tr><tr><td>--van-loading-spinner-color</td><td><em>var(--van-gray-5)</em></td><td>-</td></tr><tr><td>--van-loading-spinner-size</td><td><em>30px</em></td><td>-</td></tr><tr><td>--van-loading-spinner-animation-duration</td><td><em>0.8s</em></td><td>-</td></tr></tbody></table></div>`,16),e=[l],h={__name:"README.zh-CN",setup(c,{expose:s}){return s({frontmatter:{}}),(o,i)=>(a(),t("div",d,e))}};export{h as default};
|