{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# 转轮\n", "\n", "这个元素基于Quasar的[QSpinner组件](https://quasar.dev/vue-components/spinners)。\n", "\n", "- `type`: 转轮的类型(例如:`\"audio\"`、`\"ball\"`、`\"bars\"` 等,默认:`\"default\"`)\n", "- `size`: 转轮的大小(例如:`\"3em\"`、\"10px\"、\"xl\"等,默认:\"1em\")\n", "- `color`: 转轮的颜色(可以是Quasar、Tailwind或CSS颜色,或者 `None`,默认:`\"primary\"`)\n", "- `thickness`: 转轮的厚度(仅适用于 `\"default\"` 类型的转轮,默认:`5.0`)" ] }, { "cell_type": "code", "execution_count": 1, "metadata": {}, "outputs": [], "source": [ "from nicegui import ui\n", "\n", "with ui.row():\n", " ui.spinner(size='lg')\n", " ui.spinner('audio', size='lg', color='green')\n", " ui.spinner('dots', size='lg', color='red')\n", "\n", "# ui.run()" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [] } ], "metadata": { "kernelspec": { "display_name": "py311", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.11.7" } }, "nbformat": 4, "nbformat_minor": 2 }