Trên GitHub, tobiasahlin/SpinKit đã đạt 19.3k sao, ngôn ngữ CSS. A collection of loading indicators animated with CSS
Tóm tắt dựng từ metadata GitHub của chính dự án — chưa có bài review TopGit. Trang sẽ tự động cập nhật khi bài review đầy đủ được xuất bản.
VÌ SAO CHƯA CÓ REVIEW
TopGit viết bài đầy đủ cho repo có nhiều sao nhất và được yêu cầu nhiều nhất. Trang này là snapshot trong thời gian chờ — xem README gốc ở tab READ ME.
Simple loading spinners animated with CSS. See demo. SpinKit only uses (transform and opacity) CSS animations to create smooth and easily customizable animations.
Usage
Add spinkit.css or spinkit.min.css to your project (or copy-paste the CSS that you need for your spinner—there are no dependencies between spinners, no shared classes, and no shared animations, etc, so it should be fairly straight-forward to extract only the code that you need)
Add a spinner to your project by copy-pasting HTML from spinkit.css or examples.html
Add the sk-center utility class to the spinner to center it (it sets margin to auto)
By default, the width and height of all spinners are set to 40px. background-color is set to #333.
Configure the spinner by overwriting the CSS variables, primarily --sk-size (spinner width & height) and --sk-color (spinner color). If you need broader browser support, remove the CSS variables.
You can include SpinKit to your project with bower:
$ bower install spinkit
or npm:
$ npm install spinkit
Spinners
Given that you have included spinkit.min.css in your project, these snippets will produce the different spinners:
CSS keyframes animations are at +96.5% global support
CSS variables are at +91.8% global support
Implementing a fallback spinner
How do you know if you need to provide a fallback? You can check for animation support with Modernizr, or manually check for the animation property, and replace the spinner with a GIF if it's not supported:
function browserSupportsCSSProperty(propertyName) {
var elm = document.createElement('div');
propertyName = propertyName.toLowerCase();
if (elm.style[propertyName] != undefined)
return true;
var propertyNameCapital = propertyName.charAt(0).toUpperCase() + propertyName.substr(1),
domPrefixes = 'Webkit Moz ms O'.split(' ');
for (var i = 0; i < domPrefixes.length; i++) {
if (elm.style[domPrefixes[i] + propertyNameCapital] != undefined)
return true;
}
return false;
}
Use it to check for animation support:
if (!browserSupportsCSSProperty('animation')) {
// fallback…
}
Trang TopGit này là một snapshot — tab "Readme" hiển thị nguyên văn README của repo (đã bỏ link, giữ ảnh). Repo GitHub ở github.com/tobiasahlin/SpinKit là nguồn chính thức.
tobiasahlin/SpinKit có bao nhiêu sao?
tobiasahlin/SpinKit có 19.3k sao GitHub — tải lại trang để xem số mới nhất, hoặc xem trực tiếp github.com/tobiasahlin/SpinKit. TopGit phản chiếu số sao của GitHub nhưng không cam kết đến từng phút.
tobiasahlin/SpinKit có tag gì không?
Bản đồng bộ chưa ghi nhận topic GitHub nào cho tobiasahlin/SpinKit. GitHub topics hiển thị ở thanh bên phải trang repo — đó là nơi đáng kiểm tra nhất.
tobiasahlin/SpinKit còn đang phát triển không?
Commit gần nhất trên tobiasahlin/SpinKit là 6.3 năm trước (theo timestamp GitHub). Repo có 1.8k fork — một chỉ báo về mức độ quan tâm của cộng đồng.
tobiasahlin/SpinKit viết bằng ngôn ngữ gì?
tobiasahlin/SpinKit chủ yếu viết bằng CSS. Trường "language" của GitHub dựa trên phần lớn byte ở nhánh mặc định.
Đọc đầy đủ README ở tab phía trên.
Muốn nghe thêm một ý kiến về SpinKit?
Hỏi một AI đọc được trang này — một cú bấm là có ngay nhận định về SpinKit.