当前位置:   article > 正文

小智带你打造2023跨年烟花_2023年的跨年代码

2023年的跨年代码

       时光荏苒,白驹过隙。2022这一年又在不知不觉忙碌之中度过,过去的一年,我们同努力,我们共欢笑,每一次成功的背后都蕴藏着我们辛勤的劳动。

       不会有人还不知道这个2023跨年烟花代码吧?代码真的很浪漫,看着烟花,听着歌,跟随新年的钟声,进入满怀期待的2023年~~~程序员跨年烟花代码,赶紧安排起来!!!借着2023新年到来的喜庆佳节之际,给大家分享一个新年烟花的代码,搭配烟花燃放时的音乐,新年的氛围在此刻达到了顶峰!快来免费拿去送给你们的男朋友或女朋友~~~废话不多说,直接上图:

效果图:

 代码:

  1. <html lang="en" >
  2. <head>
  3. <meta charset="UTF-8">
  4. <title>HTML5 Canvas超逼真烟花绽放动画</title>
  5. </head>
  6. <body>
  7. <div style="height: 0; width: 0; position: absolute; visibility: hidden;">
  8. <svg xmlns="http://www.w3.org/2000/svg">
  9. <symbol id="icon-play" viewBox="0 0 24 24">
  10. <path d="M8 5v14l11-7z"/>
  11. </symbol>
  12. <symbol id="icon-pause" viewBox="0 0 24 24">
  13. <path d="M6 19h4V5H6v14zm8-14v14h4V5h-4z"/>
  14. </symbol>
  15. <symbol id="icon-close" viewBox="0 0 24 24">
  16. <path d="M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"/>
  17. </symbol>
  18. <symbol id="icon-settings" viewBox="0 0 24 24">
  19. <path d="M19.43 12.98c.04-.32.07-.64.07-.98s-.03-.66-.07-.98l2.11-1.65c.19-.15.24-.42.12-.64l-2-3.46c-.12-.22-.39-.3-.61-.22l-2.49 1c-.52-.4-1.08-.73-1.69-.98l-.38-2.65C14.46 2.18 14.25 2 14 2h-4c-.25 0-.46.18-.49.42l-.38 2.65c-.61.25-1.17.59-1.69.98l-2.49-1c-.23-.09-.49 0-.61.22l-2 3.46c-.13.22-.07.49.12.64l2.11 1.65c-.04.32-.07.65-.07.98s.03.66.07.98l-2.11 1.65c-.19.15-.24.42-.12.64l2 3.46c.12.22.39.3.61.22l2.49-1c.52.4 1.08.73 1.69.98l.38 2.65c.03.24.24.42.49.42h4c.25 0 .46-.18.49-.42l.38-2.65c.61-.25 1.17-.59 1.69-.98l2.49 1c.23.09.49 0 .61-.22l2-3.46c.12-.22.07-.49-.12-.64l-2.11-1.65zM12 15.5c-1.93 0-3.5-1.57-3.5-3.5s1.57-3.5 3.5-3.5 3.5 1.57 3.5 3.5-1.57 3.5-3.5 3.5z"/>
  20. </symbol>
  21. <symbol id="icon-sound-on" viewBox="0 0 24 24">
  22. <path d="M3 9v6h4l5 5V4L7 9H3zm13.5 3c0-1.77-1.02-3.29-2.5-4.03v8.05c1.48-.73 2.5-2.25 2.5-4.02zM14 3.23v2.06c2.89.86 5 3.54 5 6.71s-2.11 5.85-5 6.71v2.06c4.01-.91 7-4.49 7-8.77s-2.99-7.86-7-8.77z"/>
  23. </symbol>
  24. <symbol id="icon-sound-off" viewBox="0 0 24 24">
  25. <path d="M16.5 12c0-1.77-1.02-3.29-2.5-4.03v2.21l2.45 2.45c.03-.2.05-.41.05-.63zm2.5 0c0 .94-.2 1.82-.54 2.64l1.51 1.51C20.63 14.91 21 13.5 21 12c0-4.28-2.99-7.86-7-8.77v2.06c2.89.86 5 3.54 5 6.71zM4.27 3L3 4.27 7.73 9H3v6h4l5 5v-6.73l4.25 4.25c-.67.52-1.42.93-2.25 1.18v2.06c1.38-.31 2.63-.95 3.69-1.81L19.73 21 21 19.73l-9-9L4.27 3zM12 4L9.91 6.09 12 8.18V4z"/>
  26. </symbol>
  27. </svg>
  28. </div>
  29. <!-- App -->
  30. <div class="container">
  31. <div class="loading-init">
  32. <div class="loading-init__header">Loading</div>
  33. <div class="loading-init__status">Assembling Shells</div>
  34. </div>
  35. <div class="stage-container remove">
  36. <div class="canvas-container">
  37. <canvas id="trails-canvas"></canvas>
  38. <canvas id="main-canvas"></canvas>
  39. </div>
  40. <div class="controls">
  41. <div class="btn pause-btn">
  42. <svg fill="white" width="24" height="24"><use href="#icon-pause" xlink:href="#icon-pause"></use></svg>
  43. </div>
  44. <div class="btn sound-btn">
  45. <svg fill="white" width="24" height="24"><use href="#icon-sound-off" xlink:href="#icon-sound-off"></use></svg>
  46. </div>
  47. <div class="btn settings-btn">
  48. <svg fill="white" width="24" height="24"><use href="#icon-settings" xlink:href="#icon-settings"></use></svg>
  49. </div>
  50. </div>
  51. <div class="menu hide">
  52. <div class="menu__inner-wrap">
  53. <div class="btn btn--bright close-menu-btn">
  54. <svg fill="white" width="24" height="24"><use href="#icon-close" xlink:href="#icon-close"></use></svg>
  55. </div>
  56. <div class="menu__header">Settings</div>
  57. <div class="menu__subheader">For more info, click any label.</div>
  58. <form>
  59. <div class="form-option form-option--select">
  60. <label class="shell-type-label">Shell Type</label>
  61. <select class="shell-type"></select>
  62. </div>
  63. <div class="form-option form-option--select">
  64. <label class="shell-size-label">Shell Size</label>
  65. <select class="shell-size"></select>
  66. </div>
  67. <div class="form-option form-option--select">
  68. <label class="quality-ui-label">Quality</label>
  69. <select class="quality-ui"></select>
  70. </div>
  71. <div class="form-option form-option--select">
  72. <label class="sky-lighting-label">Sky Lighting</label>
  73. <select class="sky-lighting"></select>
  74. </div>
  75. <div class="form-option form-option--select">
  76. <label class="scaleFactor-label">Scale</label>
  77. <select class="scaleFactor"></select>
  78. </div>
  79. <div class="form-option form-option--checkbox">
  80. <label class="auto-launch-label">Auto Fire</label>
  81. <input class="auto-launch" type="checkbox" />
  82. </div>
  83. <div class="form-option form-option--checkbox form-option--finale-mode">
  84. <label class="finale-mode-label">Finale Mode</label>
  85. <input class="finale-mode" type="checkbox" />
  86. </div>
  87. <div class="form-option form-option--checkbox">
  88. <label class="hide-controls-label">Hide Controls</label>
  89. <input class="hide-controls" type="checkbox" />
  90. </div>
  91. <div class="form-option form-option--checkbox form-option--fullscreen">
  92. <label class="fullscreen-label">Fullscreen</label>
  93. <input class="fullscreen" type="checkbox" />
  94. </div>
  95. <div class="form-option form-option--checkbox">
  96. <label class="long-exposure-label">Open Shutter</label>
  97. <input class="long-exposure" type="checkbox" />
  98. </div>
  99. </form>
  100. <div class="credits">
  101. Passionately built by <a href="https://cmiller.tech/" target="_blank">Caleb Miller</a>.
  102. </div>
  103. </div>
  104. </div>
  105. </div>
  106. <div class="help-modal">
  107. <div class="help-modal__overlay"></div>
  108. <div class="help-modal__dialog">
  109. <div class="help-modal__header"></div>
  110. <div class="help-modal__body"></div>
  111. <button type="button" class="help-modal__close-btn">Close</button>
  112. </div>
  113. </div>
  114. </div>
  115. <script src='https://s3-us-west-2.amazonaws.com/s.cdpn.io/329180/fscreen%401.0.1.js'></script>
  116. <script src='https://s3-us-west-2.amazonaws.com/s.cdpn.io/329180/Stage%400.1.4.js'></script>
  117. <script src='https://s3-us-west-2.amazonaws.com/s.cdpn.io/329180/MyMath.js'></script><script src="./script.js"></script>
  118. </body>
  119. </html>

烟花绚烂人欢笑,饭菜飘香幸福绕,平安吉祥新年到,希望梦想随春到。

随着分分秒秒的流逝,新年的钟声已经响起

小智在这里祝大家身体健康,万事如意!!!

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/Monodyee/article/detail/116861
推荐阅读
相关标签
  

闽ICP备14008679号