码农知识堂 - 1000bd
  •   Python
  •   PHP
  •   JS/TS
  •   JAVA
  •   C/C++
  •   C#
  •   GO
  •   Kotlin
  •   Swift
  • 模拟微信小程序加载动画


    1. <template>
    2. <view class="container_app">
    3. <view class="circle">
    4. <image src="../../static/logo.png" mode="">image>
    5. view>
    6. <view class="dot">view>
    7. view>
    8. template>
    9. <script>
    10. export default {
    11. data() {
    12. return {};
    13. }
    14. }
    15. script>
    16. <style lang="less">
    17. .container_app {
    18. position: fixed;
    19. width: 100%;
    20. height: 100%;
    21. }
    22. .circle {
    23. width: 150rpx;
    24. height: 150rpx;
    25. // background-color: skyblue;
    26. border-radius: 50%;
    27. position: absolute;
    28. top: 25%;
    29. left: 50%;
    30. transform: translate(-50%,0);
    31. display: flex;
    32. justify-content: center;
    33. align-items: center;
    34. border: 4rpx solid #F1F0F2;
    35. image{
    36. width: 140rpx;
    37. height: 140rpx;
    38. border-radius: 50%;
    39. }
    40. }
    41. .dot {
    42. width: 10rpx;
    43. height: 10rpx;
    44. background-color: #56BD69;
    45. border-radius: 50%;
    46. position: absolute;
    47. top: calc(25% - 5rpx); /* 设置小圆的垂直位置为大圆的中心 */
    48. left: calc(50% - 5rpx); /* 设置小圆的水平位置为大圆的边缘 */
    49. transform-origin: 25% 82rpx; /* 将旋转中心设置为小圆自身的中心 */
    50. animation: rotate 2s linear infinite;
    51. }
    52. @keyframes rotate {
    53. from {
    54. transform: rotate(0deg) translateX(0); /* 初始位置 */
    55. }
    56. to {
    57. transform: rotate(360deg) translateX(0); /* 绕圆心旋转 */
    58. }
    59. }
    60. style>

    效果:绿圆会围着轨道旋转

            

     

  • 相关阅读:
    Vue.prototype详解
    NoSQL之Redis高可用与优化
    导入导出根文件系统脚本
    lsf基础命令
    大语言模型-LLM简介
    相似度系列—2传统方法BLEU:BLEU: a Method for Automatic Evaluation of Machine Translation
    Spring Boot Security 角色授权示例
    npm常用命令
    Java应用|使用Apache Spark MLlib构建机器学习模型【下】
    申请宣告专利权无效的主体有哪些 ?
  • 原文地址:https://blog.csdn.net/T3165919332/article/details/132430649
  • 最新文章
  • 攻防演习之三天拿下官网站群
    数据安全治理学习——前期安全规划和安全管理体系建设
    企业安全 | 企业内一次钓鱼演练准备过程
    内网渗透测试 | Kerberos协议及其部分攻击手法
    0day的产生 | 不懂代码的"代码审计"
    安装scrcpy-client模块av模块异常,环境问题解决方案
    leetcode hot100【LeetCode 279. 完全平方数】java实现
    OpenWrt下安装Mosquitto
    AnatoMask论文汇总
    【AI日记】24.11.01 LangChain、openai api和github copilot
  • 热门文章
  • 十款代码表白小特效 一个比一个浪漫 赶紧收藏起来吧!!!
    奉劝各位学弟学妹们,该打造你的技术影响力了!
    五年了,我在 CSDN 的两个一百万。
    Java俄罗斯方块,老程序员花了一个周末,连接中学年代!
    面试官都震惊,你这网络基础可以啊!
    你真的会用百度吗?我不信 — 那些不为人知的搜索引擎语法
    心情不好的时候,用 Python 画棵樱花树送给自己吧
    通宵一晚做出来的一款类似CS的第一人称射击游戏Demo!原来做游戏也不是很难,连憨憨学妹都学会了!
    13 万字 C 语言从入门到精通保姆级教程2021 年版
    10行代码集2000张美女图,Python爬虫120例,再上征途
Copyright © 2022 侵权请联系2656653265@qq.com    京ICP备2022015340号-1
正则表达式工具 cron表达式工具 密码生成工具

京公网安备 11010502049817号