mirror of
https://github.com/tabler/tabler.git
synced 2025-12-22 18:04:26 +04:00
Compare commits
1 Commits
dev-sideba
...
changeset-
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2d320870f5 |
@@ -1,6 +1,11 @@
|
|||||||
>= 1%
|
>= 1%
|
||||||
last 2 versions
|
last 1 major version
|
||||||
Firefox ESR
|
|
||||||
not dead
|
not dead
|
||||||
safari >= 15.4
|
Chrome >= 60
|
||||||
iOS >= 15.4
|
Firefox >= 60
|
||||||
|
Edge >= 15.15063
|
||||||
|
Explorer 11
|
||||||
|
iOS >= 10
|
||||||
|
Safari >= 10
|
||||||
|
Android >= 6
|
||||||
|
not ExplorerMobile <= 11
|
||||||
|
|||||||
57
.build/download-images.js
Normal file
57
.build/download-images.js
Normal file
@@ -0,0 +1,57 @@
|
|||||||
|
#!/usr/bin/env node
|
||||||
|
|
||||||
|
'use strict'
|
||||||
|
|
||||||
|
const fs = require('node:fs')
|
||||||
|
const path = require('node:path')
|
||||||
|
const request = require('request')
|
||||||
|
const filePath = path.join(__dirname, '../src/pages/_data/photos.json')
|
||||||
|
|
||||||
|
const photos = JSON.parse(fs.readFileSync(filePath, 'utf8'))
|
||||||
|
|
||||||
|
const urlTitle = (str) => {
|
||||||
|
str = str
|
||||||
|
.toLowerCase()
|
||||||
|
.replaceAll('&', 'and')
|
||||||
|
.replace(/[^[a-z0-9-]/g, '-')
|
||||||
|
.replace(/-+/g, '-')
|
||||||
|
|
||||||
|
return str
|
||||||
|
}
|
||||||
|
|
||||||
|
const download = function (uri, filename, callback, error) {
|
||||||
|
request.head(uri, function (err, res, body) {
|
||||||
|
request(uri).pipe(fs.createWriteStream(filename))
|
||||||
|
.on('close', callback)
|
||||||
|
.on('error', error)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
async function downloadPhotos() {
|
||||||
|
for (const key in photos) {
|
||||||
|
const photo = photos[key]
|
||||||
|
|
||||||
|
let filename, i = 1;
|
||||||
|
|
||||||
|
do {
|
||||||
|
filename = `${urlTitle(photo['title'])}${i > 1 ? `-${i}` : ''}.jpg`
|
||||||
|
i++
|
||||||
|
} while (fs.existsSync(path.join(__dirname, `../src/static/photos/${filename}`)))
|
||||||
|
|
||||||
|
await new Promise((resolve, reject) => {
|
||||||
|
download(photo['path'], path.join(__dirname, `../src/static/photos/${filename}`), function () {
|
||||||
|
resolve()
|
||||||
|
}, function () {
|
||||||
|
reject()
|
||||||
|
});
|
||||||
|
})
|
||||||
|
|
||||||
|
photos[key]['file'] = filename
|
||||||
|
photos[key]['horizontal'] = photo['width'] > photo['height']
|
||||||
|
}
|
||||||
|
|
||||||
|
fs.writeFileSync(filePath, JSON.stringify(photos))
|
||||||
|
}
|
||||||
|
|
||||||
|
downloadPhotos();
|
||||||
|
|
||||||
37
.build/import-icons.js
Normal file
37
.build/import-icons.js
Normal file
@@ -0,0 +1,37 @@
|
|||||||
|
#!/usr/bin/env node
|
||||||
|
|
||||||
|
'use strict'
|
||||||
|
|
||||||
|
const fs = require('fs'),
|
||||||
|
path = require('path');
|
||||||
|
|
||||||
|
const iconsTags = require('../node_modules/@tabler/icons/icons.json'),
|
||||||
|
iconsPkg = require('../node_modules/@tabler/icons/package.json');
|
||||||
|
|
||||||
|
const prepareSvgFile = (svg) => {
|
||||||
|
return svg.replace(/\n/g, '').replace(/>\s+</g, '><').replace(/\s+/g, ' ')
|
||||||
|
}
|
||||||
|
|
||||||
|
let svgList = {}
|
||||||
|
for (let iconName in iconsTags) {
|
||||||
|
let iconData = iconsTags[iconName]
|
||||||
|
svgList[iconName] = {
|
||||||
|
name: iconName,
|
||||||
|
svg: {
|
||||||
|
outline: iconData.styles.outline ? prepareSvgFile(fs.readFileSync(path.join(__dirname, `../node_modules/@tabler/icons/icons/outline/${iconName}.svg`), 'utf8')) : null,
|
||||||
|
filled: iconData.styles.filled ? prepareSvgFile(fs.readFileSync(path.join(__dirname, `../node_modules/@tabler/icons/icons/filled/${iconName}.svg`), 'utf8')) : null,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fs.writeFileSync(
|
||||||
|
path.join(__dirname, `../src/pages/_data/icons-info.json`),
|
||||||
|
JSON.stringify({
|
||||||
|
version: iconsPkg.version,
|
||||||
|
count: Object.values(svgList).reduce((acc, icon) => {
|
||||||
|
return acc + (icon.svg.outline ? 1 : 0) + (icon.svg.filled ? 1 : 0)
|
||||||
|
}, 0)
|
||||||
|
})
|
||||||
|
)
|
||||||
|
|
||||||
|
fs.writeFileSync(path.join(__dirname, `../src/pages/_data/icons.json`), JSON.stringify(svgList))
|
||||||
44
.build/import-illustrations.js
Normal file
44
.build/import-illustrations.js
Normal file
@@ -0,0 +1,44 @@
|
|||||||
|
#!/usr/bin/env node
|
||||||
|
|
||||||
|
'use strict'
|
||||||
|
|
||||||
|
const fs = require('fs'),
|
||||||
|
path = require('path'),
|
||||||
|
glob = require('glob');
|
||||||
|
|
||||||
|
const illustrations = glob
|
||||||
|
.sync(path.join(__dirname, `../src/static/illustrations/light/*.png`))
|
||||||
|
.map((file) => {
|
||||||
|
return path.basename(file, '.png')
|
||||||
|
})
|
||||||
|
|
||||||
|
fs.writeFileSync(
|
||||||
|
path.join(__dirname, `../src/pages/_data/illustrations.json`),
|
||||||
|
JSON.stringify(illustrations)
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
|
// let i = {}
|
||||||
|
// const dirs = ['light', 'dark', 'autodark']
|
||||||
|
// const ilustrations = ['not-found', 'computer-fix', 'boy-with-key', 'boy-girl']
|
||||||
|
|
||||||
|
// for(const dir of dirs) {
|
||||||
|
// i[dir] = {}
|
||||||
|
|
||||||
|
// for(const ilustration of ilustrations) {
|
||||||
|
// let svg = fs.readFileSync(path.join(__dirname, `../src/pages/_free-illustrations/${dir}/${ilustration}.svg`), 'utf8')
|
||||||
|
|
||||||
|
// svg = svg
|
||||||
|
// .replace(/\n+/g, ' ')
|
||||||
|
// .replace(/>\s+</g, '><')
|
||||||
|
// .replace(/\s+/g, ' ')
|
||||||
|
// .replace(/^[\n\s-]+/, '')
|
||||||
|
|
||||||
|
// i[dir][ilustration] = svg
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
|
||||||
|
// fs.writeFileSync(
|
||||||
|
// path.join(__dirname, `../src/pages/_data/free-illustrations.json`),
|
||||||
|
// JSON.stringify(i)
|
||||||
|
// )
|
||||||
36
.build/reformat-mdx.js
Normal file
36
.build/reformat-mdx.js
Normal file
@@ -0,0 +1,36 @@
|
|||||||
|
#!/usr/bin/env node
|
||||||
|
|
||||||
|
'use strict'
|
||||||
|
|
||||||
|
const fs = require('fs'),
|
||||||
|
path = require('path'),
|
||||||
|
glob = require('glob'),
|
||||||
|
beautifyHtml = require('js-beautify').html;
|
||||||
|
|
||||||
|
const docs = glob
|
||||||
|
.sync(path.join(__dirname, `../docs/**/*.mdx`))
|
||||||
|
|
||||||
|
docs.forEach((file, i) => {
|
||||||
|
const oldContent = fs.readFileSync(file, 'utf8')
|
||||||
|
|
||||||
|
// get codeblocks from markdown
|
||||||
|
const content = oldContent.replace(/(```([a-z0-9]+).*?\n)(.*?)(```)/gs, (m, m1, m2, m3, m4) => {
|
||||||
|
if (m2 === 'html') {
|
||||||
|
let m3m = beautifyHtml(m3, {
|
||||||
|
"indent_size": 2,
|
||||||
|
"indent_char": " ",
|
||||||
|
}).trim();
|
||||||
|
|
||||||
|
// remove empty lines
|
||||||
|
m3m = m3m.replace(/^\s*[\r\n]/gm, '');
|
||||||
|
|
||||||
|
return m1 + m3m + "\n" + m4;
|
||||||
|
}
|
||||||
|
return m
|
||||||
|
})
|
||||||
|
|
||||||
|
if (content !== oldContent) {
|
||||||
|
fs.writeFileSync(file, content, 'utf8')
|
||||||
|
console.log(`Reformatted ${file}`)
|
||||||
|
}
|
||||||
|
})
|
||||||
@@ -1,63 +0,0 @@
|
|||||||
#!/usr/bin/env node
|
|
||||||
|
|
||||||
'use strict'
|
|
||||||
|
|
||||||
import { readFileSync, writeFileSync } from 'node:fs';
|
|
||||||
import { join, dirname } from 'node:path';
|
|
||||||
import { fileURLToPath } from 'node:url'
|
|
||||||
import { sync } from 'glob';
|
|
||||||
import * as prettier from "prettier";
|
|
||||||
|
|
||||||
const __dirname = dirname(fileURLToPath(import.meta.url))
|
|
||||||
|
|
||||||
const docs = sync(join(__dirname, '..', 'docs', '**', '*.md'))
|
|
||||||
|
|
||||||
async function formatHTML(htmlString) {
|
|
||||||
try {
|
|
||||||
const formattedHtml = await prettier.format(htmlString, {
|
|
||||||
parser: "html",
|
|
||||||
printWidth: 100,
|
|
||||||
});
|
|
||||||
return formattedHtml;
|
|
||||||
} catch (error) {
|
|
||||||
console.error("Error formatting HTML:", error);
|
|
||||||
return htmlString; // Return original in case of an error
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
async function replaceAsync(str, regex, asyncFn) {
|
|
||||||
const matches = [...str.matchAll(regex)];
|
|
||||||
|
|
||||||
const replacements = await Promise.all(
|
|
||||||
matches.map(async (match) => asyncFn(...match))
|
|
||||||
);
|
|
||||||
|
|
||||||
let result = str;
|
|
||||||
matches.forEach((match, i) => {
|
|
||||||
result = result.replace(match[0], replacements[i]);
|
|
||||||
});
|
|
||||||
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
for (const file of docs) {
|
|
||||||
const oldContent = readFileSync(file, 'utf8')
|
|
||||||
|
|
||||||
// get codeblocks from markdown
|
|
||||||
const content = await replaceAsync(oldContent, /(```([a-z0-9]+).*?\n)(.*?)(```)/gs, async (m, m1, m2, m3, m4) => {
|
|
||||||
if (m2 === 'html') {
|
|
||||||
m3 = await formatHTML(m3);
|
|
||||||
|
|
||||||
// remove empty lines
|
|
||||||
m3 = m3.replace(/^\s*[\r\n]/gm, '');
|
|
||||||
|
|
||||||
return m1 + m3.trim() + "\n" + m4;
|
|
||||||
}
|
|
||||||
return m.trim();
|
|
||||||
})
|
|
||||||
|
|
||||||
if (content !== oldContent) {
|
|
||||||
writeFileSync(file, content, 'utf8')
|
|
||||||
console.log(`Reformatted ${file}`)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
26
.build/unused-files.js
Normal file
26
.build/unused-files.js
Normal file
@@ -0,0 +1,26 @@
|
|||||||
|
const glob = require('glob');
|
||||||
|
const fs = require('fs')
|
||||||
|
const path = require('path')
|
||||||
|
|
||||||
|
const srcDir = path.join(__dirname, '../src')
|
||||||
|
|
||||||
|
let foundFiles = []
|
||||||
|
glob.sync(`${srcDir}/pages/**/*.{html,md}`).forEach((file) => {
|
||||||
|
let fileContent = fs.readFileSync(file)
|
||||||
|
|
||||||
|
fileContent.toString().replace(/\{% include(_cached)? "([a-z0-9\/_-]+\.html)"/g, (f, c, filename) => {
|
||||||
|
filename = `${srcDir}/pages/_includes/${filename}`
|
||||||
|
|
||||||
|
if (!foundFiles.includes(filename)) {
|
||||||
|
foundFiles.push(filename)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
let includeFiles = glob.sync(`${srcDir}/pages/_includes/**/*.html`)
|
||||||
|
|
||||||
|
includeFiles.forEach((file) => {
|
||||||
|
if (!foundFiles.includes(file)) {
|
||||||
|
console.log('file', file)
|
||||||
|
}
|
||||||
|
})
|
||||||
@@ -1,30 +0,0 @@
|
|||||||
#!/usr/bin/env node
|
|
||||||
|
|
||||||
import AdmZip from 'adm-zip';
|
|
||||||
import path from 'path';
|
|
||||||
import { fileURLToPath } from 'url';
|
|
||||||
import { readFileSync } from 'fs';
|
|
||||||
|
|
||||||
// Get __dirname in ESM
|
|
||||||
const __dirname = path.dirname(fileURLToPath(import.meta.url))
|
|
||||||
|
|
||||||
const pkg = JSON.parse(
|
|
||||||
readFileSync(path.join(__dirname, '../core', 'package.json'), 'utf8')
|
|
||||||
)
|
|
||||||
|
|
||||||
// Create zip instance and add folder
|
|
||||||
const zip = new AdmZip();
|
|
||||||
zip.addLocalFolder(path.join(__dirname, '../preview/dist'), 'dashboard');
|
|
||||||
|
|
||||||
zip.addLocalFile(path.join(__dirname, '../preview/static', 'og.png'), '.', 'preview.png');
|
|
||||||
|
|
||||||
zip.addFile("documentation.url", Buffer.from("[InternetShortcut]\nURL = https://tabler.io/docs"));
|
|
||||||
|
|
||||||
|
|
||||||
// Folder to zip and output path
|
|
||||||
const outputZipPath = path.join(__dirname, '../packages-zip', `tabler-${pkg.version}.zip`);
|
|
||||||
|
|
||||||
// Write the zip file
|
|
||||||
zip.writeZip(outputZipPath);
|
|
||||||
|
|
||||||
console.log(`Zipped folder to ${outputZipPath}`);
|
|
||||||
@@ -1,6 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/core": minor
|
|
||||||
"@tabler/preview": minor
|
|
||||||
---
|
|
||||||
|
|
||||||
Added Pay page with dedicated layout, navigation link, and card/PayPal payment form.
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/core": minor
|
|
||||||
---
|
|
||||||
|
|
||||||
Added `.btn-ghost` button variant with transparent background and hover effects.
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/preview": minor
|
|
||||||
---
|
|
||||||
|
|
||||||
Added color palette to signing component.
|
|
||||||
@@ -3,18 +3,8 @@
|
|||||||
"changelog": "@changesets/cli/changelog",
|
"changelog": "@changesets/cli/changelog",
|
||||||
"commit": false,
|
"commit": false,
|
||||||
"fixed": [],
|
"fixed": [],
|
||||||
"linked": [
|
"linked": [],
|
||||||
[
|
|
||||||
"@tabler/core",
|
|
||||||
"@tabler/preview",
|
|
||||||
"@tabler/docs"
|
|
||||||
]
|
|
||||||
],
|
|
||||||
"access": "public",
|
"access": "public",
|
||||||
"baseBranch": "dev",
|
"baseBranch": "main",
|
||||||
"ignore": [],
|
"ignore": []
|
||||||
"privatePackages": {
|
|
||||||
"version": true,
|
|
||||||
"tag": false
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/core": patch
|
|
||||||
---
|
|
||||||
|
|
||||||
Fixed icon alignment for `.btn-sm` and `.btn-xl` sizes.
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/core": patch
|
|
||||||
---
|
|
||||||
|
|
||||||
Fixed mixed declarations in SCSS.
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/core": patch
|
|
||||||
---
|
|
||||||
|
|
||||||
Updated `stroke-width` for `.icon-sm` from `1` to `1.5` for better visibility.
|
|
||||||
@@ -1,6 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/core": patch
|
|
||||||
"@tabler/preview": patch
|
|
||||||
---
|
|
||||||
|
|
||||||
Added `bg-blur` utility and increased `container-tight` width for layout flexibility.
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/preview": patch
|
|
||||||
---
|
|
||||||
|
|
||||||
Updated icons to v3.34.1 with 75 new icons.
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/preview": patch
|
|
||||||
---
|
|
||||||
|
|
||||||
Updated activity messages.
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/preview": minor
|
|
||||||
---
|
|
||||||
|
|
||||||
Added new onboarding page with progress indicator and navigation layout.
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/core": patch
|
|
||||||
---
|
|
||||||
|
|
||||||
Fixed double bottom border in tables.
|
|
||||||
@@ -1,6 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/core": minor
|
|
||||||
"@tabler/preview": minor
|
|
||||||
---
|
|
||||||
|
|
||||||
Added Progress Background component with text labels and value display.
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/core": minor
|
|
||||||
---
|
|
||||||
|
|
||||||
Added `.progress-lg` and `.progress-xl` size variants for the progress component.
|
|
||||||
@@ -1,6 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/core": minor
|
|
||||||
"@tabler/preview": minor
|
|
||||||
---
|
|
||||||
|
|
||||||
Added Progress Steps component for step-by-step navigation indicators.
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/core": patch
|
|
||||||
---
|
|
||||||
|
|
||||||
Added smooth transitions for progress bar `width` and `background-color` changes.
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/core": patch
|
|
||||||
---
|
|
||||||
|
|
||||||
Updated skip-link to use `visually-hidden` for improved accessibility.
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/core": patch
|
|
||||||
---
|
|
||||||
|
|
||||||
Updated deprecated global Sass functions to module equivalents (`map.merge`, `string.slice`, `math.percentage`, etc.).
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/core": patch
|
|
||||||
---
|
|
||||||
|
|
||||||
Updated Bootstrap to v5.3.8.
|
|
||||||
@@ -1,6 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/core": patch
|
|
||||||
"@tabler/preview": patch
|
|
||||||
---
|
|
||||||
|
|
||||||
Updated trending component to use `arrow-up`/`arrow-down` instead of `trending-up`/`trending-down`.
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/docs": patch
|
|
||||||
---
|
|
||||||
|
|
||||||
Fixed Docs search display in dark mode.
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
---
|
|
||||||
"@tabler/preview": patch
|
|
||||||
---
|
|
||||||
|
|
||||||
Fixed responsive layouts on the Form Elements page.
|
|
||||||
@@ -1,100 +0,0 @@
|
|||||||
---
|
|
||||||
description: Cursor Rules for Tabler Changesets
|
|
||||||
globs:
|
|
||||||
alwaysApply: true
|
|
||||||
---
|
|
||||||
|
|
||||||
|
|
||||||
### File Structure
|
|
||||||
|
|
||||||
- Each change must be in a separate changeset file in `.changeset/` directory
|
|
||||||
- Use descriptive kebab-case filenames (e.g., `progress-sizes.md`, `button-ghost.md`)
|
|
||||||
- Follow the standard changeset format with frontmatter and description
|
|
||||||
|
|
||||||
### Change Description Format
|
|
||||||
|
|
||||||
- **One sentence per changeset** - keep descriptions concise and focused
|
|
||||||
- Use **backticks for code elements**: classes (`.btn-ghost`), properties (`stroke-width`), values (`1.5`), icons (`arrow-up`)
|
|
||||||
- Start with action verbs: "Added", "Updated", "Fixed", "Removed"
|
|
||||||
- Be specific about what was changed
|
|
||||||
|
|
||||||
### Version Bump Guidelines
|
|
||||||
|
|
||||||
- **Major**: Breaking changes, complete rewrites
|
|
||||||
- **Minor**: New features, new components, new pages, significant enhancements
|
|
||||||
- **Patch**: Bug fixes, small improvements, style updates, accessibility fixes
|
|
||||||
|
|
||||||
### Package Selection
|
|
||||||
|
|
||||||
- `"@tabler/core"`: Changes to SCSS, core functionality, CSS classes
|
|
||||||
- `"@tabler/preview"`: New pages, demo updates, preview-specific changes
|
|
||||||
- `"@tabler/docs"`: Documentation updates
|
|
||||||
- Use multiple packages when change affects multiple areas
|
|
||||||
|
|
||||||
### Examples
|
|
||||||
|
|
||||||
#### New Feature (Minor)
|
|
||||||
|
|
||||||
```md
|
|
||||||
---
|
|
||||||
"@tabler/core": minor
|
|
||||||
"@tabler/preview": minor
|
|
||||||
---
|
|
||||||
|
|
||||||
Added Progress Steps component for step-by-step navigation indicators.
|
|
||||||
```
|
|
||||||
|
|
||||||
#### Bug Fix (Patch)
|
|
||||||
|
|
||||||
```md
|
|
||||||
---
|
|
||||||
"@tabler/core": patch
|
|
||||||
---
|
|
||||||
|
|
||||||
Updated `stroke-width` for `.icon-sm` from `1` to `1.5` for better visibility.
|
|
||||||
```
|
|
||||||
|
|
||||||
#### New Page (Minor)
|
|
||||||
|
|
||||||
```md
|
|
||||||
---
|
|
||||||
"@tabler/preview": minor
|
|
||||||
---
|
|
||||||
|
|
||||||
Added new onboarding page with progress indicator and navigation layout.
|
|
||||||
```
|
|
||||||
|
|
||||||
#### Style Enhancement (Patch)
|
|
||||||
|
|
||||||
```md
|
|
||||||
---
|
|
||||||
"@tabler/core": patch
|
|
||||||
---
|
|
||||||
|
|
||||||
Added smooth transitions for progress bar width and background color changes.
|
|
||||||
```
|
|
||||||
|
|
||||||
### Code Formatting Rules
|
|
||||||
|
|
||||||
- Class names: `.btn-ghost`, `.progress-lg`, `.icon-sm`
|
|
||||||
- CSS properties: `stroke-width`, `background-color`, `width`
|
|
||||||
- Values: `1.5`, `transparent`, `100%`
|
|
||||||
- Icon names: `arrow-up`, `arrow-down`, `trending-up`
|
|
||||||
- HTML attributes: `aria-label`, `role`, `data-*`
|
|
||||||
- JavaScript functions: `addEventListener()`, `querySelector()`
|
|
||||||
|
|
||||||
### Common Patterns
|
|
||||||
|
|
||||||
- **Component additions**: "Added [ComponentName] component for [purpose]"
|
|
||||||
- **Size variants**: "Added [size] size variant for [component] (`.class-size`)"
|
|
||||||
- **Style fixes**: "Fixed [issue] in [component/element]"
|
|
||||||
- **Icon updates**: "Updated [component] to use `new-icon` instead of `old-icon`"
|
|
||||||
- **Accessibility**: "Improved accessibility by [specific change]"
|
|
||||||
|
|
||||||
### Commit Message Format
|
|
||||||
|
|
||||||
Use English for commit messages following conventional commit format when possible:
|
|
||||||
|
|
||||||
- `feat: add progress steps component`
|
|
||||||
- `fix: update icon stroke width for better visibility`
|
|
||||||
- `style: add smooth transitions to progress bars`
|
|
||||||
@@ -1,171 +0,0 @@
|
|||||||
---
|
|
||||||
description: Tabler Project HTML Elements Guidelines
|
|
||||||
globs: ["**/*.html", "**/*.liquid", "**/*.md"]
|
|
||||||
alwaysApply: true
|
|
||||||
---
|
|
||||||
|
|
||||||
## HTML Elements Guidelines
|
|
||||||
|
|
||||||
### 1. Icons
|
|
||||||
|
|
||||||
When you need to use an icon, always use the Tabler icon include syntax:
|
|
||||||
|
|
||||||
```html
|
|
||||||
{% include "ui/icon.html" icon="ICON_NAME" %}
|
|
||||||
```
|
|
||||||
|
|
||||||
**Examples:**
|
|
||||||
|
|
||||||
- `{% include "ui/icon.html" icon="home" %}`
|
|
||||||
- `{% include "ui/icon.html" icon="building-community" %}`
|
|
||||||
- `{% include "ui/icon.html" icon="map-pin" %}`
|
|
||||||
|
|
||||||
### 2. Page Links
|
|
||||||
|
|
||||||
When linking to other pages, always use the relative page syntax:
|
|
||||||
|
|
||||||
```html
|
|
||||||
href="{{ page | relative }}/url.html"
|
|
||||||
```
|
|
||||||
|
|
||||||
**Examples:**
|
|
||||||
|
|
||||||
- `href="{{ page | relative }}/job-post.html"`
|
|
||||||
- `href="{{ page | relative }}/job-listing.html"`
|
|
||||||
- `href="{{ page | relative }}/marketing/index.html"`
|
|
||||||
|
|
||||||
### 3. Static Generation
|
|
||||||
|
|
||||||
All pages are statically generated to HTML using Eleventy (11ty). Keep this in mind when:
|
|
||||||
|
|
||||||
- Writing frontmatter (must be static YAML, no Liquid templating)
|
|
||||||
- Creating dynamic content (use Liquid templating in the body, not frontmatter)
|
|
||||||
- Linking between pages (use relative paths)
|
|
||||||
|
|
||||||
### 4. Additional Guidelines
|
|
||||||
|
|
||||||
#### Frontmatter Rules
|
|
||||||
|
|
||||||
- Frontmatter must be static YAML
|
|
||||||
- Cannot use Liquid templating in frontmatter
|
|
||||||
- Use static values for title, permalink, etc.
|
|
||||||
|
|
||||||
#### Liquid Templating
|
|
||||||
|
|
||||||
- Use Liquid templating only in the HTML body
|
|
||||||
- Access data using `{{ variable }}` syntax
|
|
||||||
- Use `{% for %}` loops for dynamic content
|
|
||||||
- Use `{% if %}` conditions for conditional rendering
|
|
||||||
|
|
||||||
#### File Structure
|
|
||||||
|
|
||||||
- Pages go in `preview/pages/`
|
|
||||||
- Includes go in `shared/includes/`
|
|
||||||
- Data files go in `shared/data/`
|
|
||||||
- Documentation goes in `docs/content/`
|
|
||||||
|
|
||||||
#### CSS Classes
|
|
||||||
|
|
||||||
- Use Bootstrap 5 classes
|
|
||||||
- Use Tabler's custom CSS classes
|
|
||||||
- Follow the pattern: `--#{$prefix}component-property`
|
|
||||||
|
|
||||||
#### Accessibility
|
|
||||||
|
|
||||||
- Include proper ARIA labels
|
|
||||||
- Use semantic HTML elements
|
|
||||||
- Ensure proper heading hierarchy
|
|
||||||
- Add alt text for images
|
|
||||||
|
|
||||||
### 5. Component Usage
|
|
||||||
|
|
||||||
#### Cards
|
|
||||||
|
|
||||||
- Use `card` class for main containers
|
|
||||||
- Use `card-body` for content areas
|
|
||||||
- Use `card-header` for card headers
|
|
||||||
- Use `card-title` for card title
|
|
||||||
|
|
||||||
#### Buttons
|
|
||||||
|
|
||||||
- Use `btn` class for all buttons
|
|
||||||
- Use `btn-primary` for primary actions
|
|
||||||
- Use `btn` for secondary actions, don't use `btn-outline-secondary`
|
|
||||||
- Use `btn-sm` for smaller buttons
|
|
||||||
- Use `w-100` for full-width buttons
|
|
||||||
|
|
||||||
#### Forms
|
|
||||||
|
|
||||||
- Use `form-control` for input fields
|
|
||||||
- Use `form-label` for labels
|
|
||||||
- Use `form-check` for checkboxes/radio buttons
|
|
||||||
- Use `form-select` for dropdowns
|
|
||||||
|
|
||||||
#### Layout
|
|
||||||
|
|
||||||
- Use Bootstrap grid system (`row`, `col-*`)
|
|
||||||
- Use `container-xl` for main containers
|
|
||||||
- Use `page-wrapper` for page structure
|
|
||||||
- Use `page-body` for main content area
|
|
||||||
|
|
||||||
#### Badges
|
|
||||||
|
|
||||||
- Use `badge` class for badges
|
|
||||||
- Don't use `badge-outline` for badges, use `badge` class instead
|
|
||||||
- Don't use `badge-primary` for badges, use `badge` class instead
|
|
||||||
- Don't change the text color of badges
|
|
||||||
|
|
||||||
#### Markdown
|
|
||||||
|
|
||||||
- Use `markdown` class for markdown content
|
|
||||||
- Apply to containers that render markdown content
|
|
||||||
- Example: `<div class="markdown">...</div>`
|
|
||||||
|
|
||||||
#### Rest of the rules
|
|
||||||
|
|
||||||
- Read the rest of the rules in the `docs/content/ui/` folder
|
|
||||||
|
|
||||||
### 6. Data Integration
|
|
||||||
|
|
||||||
#### Using JSON Data
|
|
||||||
|
|
||||||
```liquid
|
|
||||||
{% for item in items %}
|
|
||||||
<div>{{ item.name }}</div>
|
|
||||||
{% endfor %}
|
|
||||||
```
|
|
||||||
|
|
||||||
#### Conditional Rendering
|
|
||||||
|
|
||||||
```liquid
|
|
||||||
{% if condition %}
|
|
||||||
<div>Content</div>
|
|
||||||
{% endif %}
|
|
||||||
```
|
|
||||||
|
|
||||||
#### Including Components
|
|
||||||
|
|
||||||
```liquid
|
|
||||||
{% include "ui/button.html" color="primary" text="Click me" %}
|
|
||||||
```
|
|
||||||
|
|
||||||
### 7. Best Practices
|
|
||||||
|
|
||||||
#### Performance
|
|
||||||
|
|
||||||
- Minimize nested loops
|
|
||||||
- Use `limit` filters when iterating large datasets
|
|
||||||
- Optimize images for web use
|
|
||||||
|
|
||||||
#### Code Organization
|
|
||||||
|
|
||||||
- Keep components modular and reusable
|
|
||||||
- Use consistent naming conventions
|
|
||||||
- Comment complex logic
|
|
||||||
- Group related functionality together
|
|
||||||
|
|
||||||
#### Error Handling
|
|
||||||
|
|
||||||
- Always check if data exists before using it
|
|
||||||
- Provide fallback content for missing data
|
|
||||||
- Use `{% if %}` guards for optional content
|
|
||||||
@@ -1,56 +0,0 @@
|
|||||||
---
|
|
||||||
description: Tabler Project Rules
|
|
||||||
globs:
|
|
||||||
alwaysApply: true
|
|
||||||
---
|
|
||||||
|
|
||||||
## Documentation Standards
|
|
||||||
|
|
||||||
- Always write documentation in English (not Polish) for technical content
|
|
||||||
- Use clear, descriptive headings with proper hierarchy (##, ###)
|
|
||||||
- Include practical examples with code snippets
|
|
||||||
- Add explanations for each component's purpose and usage
|
|
||||||
- Use consistent formatting for code blocks and examples
|
|
||||||
|
|
||||||
## CSS/SCSS Guidelines
|
|
||||||
|
|
||||||
- Follow Tabler's CSS custom properties pattern: `--#{$prefix}component-property`
|
|
||||||
- Use semantic class names that describe purpose, not appearance
|
|
||||||
- Maintain consistent spacing and indentation in SCSS files
|
|
||||||
- Group related styles together with clear comments
|
|
||||||
- Use Bootstrap-compatible class naming conventions
|
|
||||||
|
|
||||||
## Component Documentation Structure
|
|
||||||
|
|
||||||
- Start with a brief description of the component's purpose
|
|
||||||
- Show basic usage examples first
|
|
||||||
- Include variations and modifiers
|
|
||||||
- Add accessibility considerations where relevant
|
|
||||||
- Provide code examples that are copy-paste ready
|
|
||||||
|
|
||||||
## File Organization
|
|
||||||
|
|
||||||
- Keep documentation files in `docs/content/ui/components/`
|
|
||||||
- Use consistent naming: lowercase with hyphens
|
|
||||||
- Include frontmatter with title, summary, and description
|
|
||||||
- Link to Bootstrap documentation when relevant
|
|
||||||
|
|
||||||
## Code Examples
|
|
||||||
|
|
||||||
- Use Liquid templating syntax for dynamic examples
|
|
||||||
- Include both HTML and rendered output
|
|
||||||
- Show responsive behavior where applicable
|
|
||||||
- Demonstrate proper accessibility attributes
|
|
||||||
|
|
||||||
## Git Commit Messages
|
|
||||||
|
|
||||||
- Use English for commit messages
|
|
||||||
- Follow conventional commit format when possible
|
|
||||||
- Be descriptive about what was changed and why
|
|
||||||
|
|
||||||
## Project-Specific Conventions
|
|
||||||
|
|
||||||
- Tabler uses Bootstrap 5 as a foundation
|
|
||||||
- Custom components extend Bootstrap functionality
|
|
||||||
- Documentation should be comprehensive but concise
|
|
||||||
- Examples should be practical and immediately usable
|
|
||||||
68
.github/workflows/argos.yml
vendored
68
.github/workflows/argos.yml
vendored
@@ -1,68 +0,0 @@
|
|||||||
name: Argos Tests
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches:
|
|
||||||
- dev
|
|
||||||
pull_request:
|
|
||||||
paths:
|
|
||||||
- 'preview/**/*.js'
|
|
||||||
- 'preview/**/*.html'
|
|
||||||
- 'preview/**/*.scss'
|
|
||||||
- 'core/**/*.js'
|
|
||||||
- 'core/**/*.scss'
|
|
||||||
|
|
||||||
env:
|
|
||||||
NODE: 20
|
|
||||||
|
|
||||||
permissions:
|
|
||||||
contents: read
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
test:
|
|
||||||
timeout-minutes: 60
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
# if: github.event.pull_request.draft == false
|
|
||||||
if: false
|
|
||||||
steps:
|
|
||||||
- name: Clone repository
|
|
||||||
uses: actions/checkout@v5
|
|
||||||
|
|
||||||
- name: Cache turbo build setup
|
|
||||||
uses: actions/cache@v4
|
|
||||||
with:
|
|
||||||
path: .turbo
|
|
||||||
key: ${{ runner.os }}-turbo-${{ github.sha }}
|
|
||||||
restore-keys: |
|
|
||||||
${{ runner.os }}-turbo-
|
|
||||||
|
|
||||||
- name: Install PNPM
|
|
||||||
uses: pnpm/action-setup@v4
|
|
||||||
|
|
||||||
- name: Set up Node.js
|
|
||||||
uses: actions/setup-node@v5
|
|
||||||
with:
|
|
||||||
node-version: "${{ env.NODE }}"
|
|
||||||
cache: 'pnpm'
|
|
||||||
|
|
||||||
- name: Get installed Playwright version
|
|
||||||
id: playwright-version
|
|
||||||
run: echo "PLAYWRIGHT_VERSION=$(node -e "console.log(require('./package.json').devDependencies['@playwright/test'])")" >> $GITHUB_ENV
|
|
||||||
|
|
||||||
- name: Cache playwright binaries
|
|
||||||
uses: actions/cache@v4
|
|
||||||
id: playwright-cache
|
|
||||||
with:
|
|
||||||
path: |
|
|
||||||
~/.cache/ms-playwright
|
|
||||||
key: ${{ runner.os }}-playwright-${{ env.PLAYWRIGHT_VERSION }}
|
|
||||||
|
|
||||||
- name: Install pnpm dependencies
|
|
||||||
run: pnpm install
|
|
||||||
|
|
||||||
- name: Install Playwright Browsers
|
|
||||||
run: pnpm exec playwright install --with-deps
|
|
||||||
if: steps.playwright-cache.outputs.cache-hit != 'true'
|
|
||||||
|
|
||||||
- name: Run Playwright tests
|
|
||||||
run: pnpm run playwright
|
|
||||||
24
.github/workflows/bundlewatch.yml
vendored
24
.github/workflows/bundlewatch.yml
vendored
@@ -17,24 +17,17 @@ jobs:
|
|||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Clone repository
|
- name: Clone repository
|
||||||
uses: actions/checkout@v5
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Cache turbo build setup
|
|
||||||
uses: actions/cache@v4
|
|
||||||
with:
|
|
||||||
path: .turbo
|
|
||||||
key: ${{ runner.os }}-turbo-${{ github.sha }}
|
|
||||||
restore-keys: |
|
|
||||||
${{ runner.os }}-turbo-
|
|
||||||
|
|
||||||
- name: Install PNPM
|
|
||||||
uses: pnpm/action-setup@v4
|
|
||||||
|
|
||||||
- name: Set up Node.js
|
- name: Set up Node.js
|
||||||
uses: actions/setup-node@v5
|
uses: actions/setup-node@v4
|
||||||
with:
|
with:
|
||||||
node-version: "${{ env.NODE }}"
|
node-version: "${{ env.NODE }}"
|
||||||
cache: 'pnpm'
|
|
||||||
|
- name: Install PNPM
|
||||||
|
uses: pnpm/action-setup@v4
|
||||||
|
with:
|
||||||
|
version: 8
|
||||||
|
|
||||||
- name: Set up Bundler
|
- name: Set up Bundler
|
||||||
uses: ruby/setup-ruby@v1
|
uses: ruby/setup-ruby@v1
|
||||||
@@ -45,6 +38,9 @@ jobs:
|
|||||||
- name: Install pnpm dependencies
|
- name: Install pnpm dependencies
|
||||||
run: pnpm install --no-frozen-lockfile
|
run: pnpm install --no-frozen-lockfile
|
||||||
|
|
||||||
|
- name: Run build
|
||||||
|
run: pnpm run build
|
||||||
|
|
||||||
- name: Run bundlewatch
|
- name: Run bundlewatch
|
||||||
run: pnpm run bundlewatch
|
run: pnpm run bundlewatch
|
||||||
env:
|
env:
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout Repo
|
- name: Checkout Repo
|
||||||
uses: actions/checkout@v5
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
persist-credentials: false
|
persist-credentials: false
|
||||||
|
|
||||||
|
|||||||
2
.github/workflows/close_inactive.yml
vendored
2
.github/workflows/close_inactive.yml
vendored
@@ -11,7 +11,7 @@ jobs:
|
|||||||
pull-requests: write
|
pull-requests: write
|
||||||
issues: write
|
issues: write
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/stale@v10
|
- uses: actions/stale@v9
|
||||||
with:
|
with:
|
||||||
days-before-issue-stale: 360
|
days-before-issue-stale: 360
|
||||||
days-before-issue-close: 14
|
days-before-issue-close: 14
|
||||||
|
|||||||
12
.github/workflows/lockfiles.yaml
vendored
12
.github/workflows/lockfiles.yaml
vendored
@@ -1,7 +1,6 @@
|
|||||||
name: Changed lock files
|
name: Changed lock files
|
||||||
on:
|
on:
|
||||||
pull_request_target:
|
pull_request: null
|
||||||
types: [opened, reopened]
|
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
pull-requests: read
|
pull-requests: read
|
||||||
@@ -12,10 +11,11 @@ jobs:
|
|||||||
name: Verify lock file integrity
|
name: Verify lock file integrity
|
||||||
steps:
|
steps:
|
||||||
- name: Clone Tabler
|
- name: Clone Tabler
|
||||||
uses: actions/checkout@v5
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Prevent lock file change
|
- name: Prevent lock file change
|
||||||
uses: xalvarez/prevent-file-change-action@v2
|
uses: xalvarez/prevent-file-change-action@v1
|
||||||
with:
|
with:
|
||||||
githubToken: ${{ secrets.GITHUB_TOKEN }}
|
githubToken: ${{ secrets.GITHUB_TOKEN }}
|
||||||
pattern: Gemfile.lock|pnpm-lock.json|pnpm-lock.yaml
|
pattern: Gemfile.lock|pnpm-lock.json
|
||||||
trustedAuthors: codecalm, BG-Software-BG, dependabot
|
trustedAuthors: codecalm, dependabot
|
||||||
|
|||||||
14
.github/workflows/release.yml
vendored
14
.github/workflows/release.yml
vendored
@@ -3,6 +3,7 @@ name: Release
|
|||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
|
- main
|
||||||
- dev
|
- dev
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
@@ -21,16 +22,17 @@ jobs:
|
|||||||
pull-requests: write # to create pull request
|
pull-requests: write # to create pull request
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout Repo
|
- name: Checkout Repo
|
||||||
uses: actions/checkout@v5
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: Setup Node.js 18
|
||||||
|
uses: actions/setup-node@v4
|
||||||
|
with:
|
||||||
|
node-version: 20
|
||||||
|
|
||||||
- name: Install PNPM
|
- name: Install PNPM
|
||||||
uses: pnpm/action-setup@v4
|
uses: pnpm/action-setup@v4
|
||||||
|
|
||||||
- name: Setup Node.js 18
|
|
||||||
uses: actions/setup-node@v5
|
|
||||||
with:
|
with:
|
||||||
node-version: "${{ env.NODE }}"
|
version: 8
|
||||||
cache: 'pnpm'
|
|
||||||
|
|
||||||
- name: Install Dependencies
|
- name: Install Dependencies
|
||||||
run: pnpm install
|
run: pnpm install
|
||||||
|
|||||||
22
.github/workflows/test.yml
vendored
22
.github/workflows/test.yml
vendored
@@ -1,7 +1,8 @@
|
|||||||
name: Test build
|
name: Test build
|
||||||
|
|
||||||
on:
|
on:
|
||||||
pull_request: null
|
pull_request:
|
||||||
|
types: [ opened, reopened ]
|
||||||
|
|
||||||
env:
|
env:
|
||||||
NODE: 20
|
NODE: 20
|
||||||
@@ -14,24 +15,17 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Clone repository
|
- name: Clone repository
|
||||||
uses: actions/checkout@v5
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Cache turbo build setup
|
- name: Set up Node.js
|
||||||
uses: actions/cache@v4
|
uses: actions/setup-node@v4
|
||||||
with:
|
with:
|
||||||
path: .turbo
|
node-version: "${{ env.NODE }}"
|
||||||
key: ${{ runner.os }}-turbo-${{ github.sha }}
|
|
||||||
restore-keys: |
|
|
||||||
${{ runner.os }}-turbo-
|
|
||||||
|
|
||||||
- name: Install PNPM
|
- name: Install PNPM
|
||||||
uses: pnpm/action-setup@v4
|
uses: pnpm/action-setup@v4
|
||||||
|
|
||||||
- name: Set up Node.js
|
|
||||||
uses: actions/setup-node@v5
|
|
||||||
with:
|
with:
|
||||||
node-version: "${{ env.NODE }}"
|
version: 8
|
||||||
cache: 'pnpm'
|
|
||||||
|
|
||||||
- run: node --version
|
- run: node --version
|
||||||
|
|
||||||
|
|||||||
12
.gitignore
vendored
12
.gitignore
vendored
@@ -19,21 +19,17 @@ node_modules/
|
|||||||
/svg-tmp/
|
/svg-tmp/
|
||||||
/components/
|
/components/
|
||||||
/percy.sh
|
/percy.sh
|
||||||
/preview/pages/playground.html
|
/src/pages/playground.html
|
||||||
/preview/pages/screenshot.html
|
/src/pages/playground-*.html
|
||||||
/preview/pages/screenshot-*.html
|
/src/pages/features.html
|
||||||
/preview/pages/playground-*.html
|
|
||||||
/preview/pages/features.html
|
|
||||||
|
|
||||||
.pnp.loader.mjs
|
.pnp.loader.mjs
|
||||||
.pnp.cjs
|
.pnp.cjs
|
||||||
.yarn
|
.yarn
|
||||||
.next
|
.next
|
||||||
.vercel
|
.vercel
|
||||||
.turbo
|
|
||||||
package-lock.json
|
package-lock.json
|
||||||
|
|
||||||
demo/
|
demo/
|
||||||
dist/
|
dist/
|
||||||
packages-zip/
|
packages-zip/
|
||||||
.env
|
|
||||||
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"bracketSpacing": true,
|
"bracketSpacing": true,
|
||||||
"jsxSingleQuote": false,
|
"jsxSingleQuote": false,
|
||||||
"printWidth": 320,
|
"printWidth": 240,
|
||||||
"proseWrap": "always",
|
"proseWrap": "always",
|
||||||
"semi": false,
|
"semi": false,
|
||||||
"singleQuote": false,
|
"singleQuote": false,
|
||||||
|
|||||||
16
.vscode/settings.json
vendored
16
.vscode/settings.json
vendored
@@ -1,12 +1,14 @@
|
|||||||
{
|
{
|
||||||
"files.exclude": {
|
"files.exclude": {
|
||||||
"**/.git": true,
|
"**/.git": false,
|
||||||
"**/.svn": true,
|
"**/.svn": false,
|
||||||
"**/.hg": true,
|
"**/.hg": false,
|
||||||
"**/CVS": true,
|
"**/CVS": false,
|
||||||
"**/.DS_Store": true,
|
"**/.DS_Store": false,
|
||||||
"**/Thumbs.db": true,
|
"**/Thumbs.db": false,
|
||||||
"**/.idea/": true
|
"**/.idea/": false,
|
||||||
|
"dist": false,
|
||||||
|
"demo": false
|
||||||
},
|
},
|
||||||
"explorerExclude.backup": {}
|
"explorerExclude.backup": {}
|
||||||
}
|
}
|
||||||
@@ -1,138 +1,10 @@
|
|||||||
# @tabler/core
|
# Changelog
|
||||||
|
|
||||||
## 1.4.0
|
## 1.0.1
|
||||||
|
|
||||||
### Minor Changes
|
|
||||||
|
|
||||||
- 9951fe9: Enhance button and hover animations
|
|
||||||
- a200d30: Improve breadcrumb styles
|
|
||||||
- 49ab9ea: Add new Tabler Illustrations
|
|
||||||
|
|
||||||
### Patch Changes
|
### Patch Changes
|
||||||
|
|
||||||
- 6c4dd36: Update class names from `*-left`, `*-right` to `*-start`, `*-end`
|
|
||||||
- 6fec73a: Fix relative line heights in buttons
|
|
||||||
- db6200a: Remove `license_key` option from HugeRTE init object
|
|
||||||
- e96f055: Add different favicon to development environment
|
|
||||||
- 6c38a48: Update Bootstrap to v5.3.7
|
|
||||||
- 2a12f72: Update CSS calculations to use `calc()`
|
|
||||||
- 666a296: Fix list group item hoverable only with `.list-group-hoverable` class
|
|
||||||
- cfd4cb6: Fix `.pagination-link` hover styles to non-active items
|
|
||||||
|
|
||||||
## 1.3.2
|
|
||||||
|
|
||||||
### Patch Changes
|
|
||||||
|
|
||||||
- 446c34e: Fix README file in core package
|
|
||||||
|
|
||||||
## 1.3.1
|
|
||||||
|
|
||||||
### Patch Changes
|
|
||||||
|
|
||||||
- a7f73d7: Fix README file in core package
|
|
||||||
|
|
||||||
## 1.3.0
|
|
||||||
|
|
||||||
### Minor Changes
|
|
||||||
|
|
||||||
- a1af801: Add FullCalendar integration
|
|
||||||
- b9d434d: Add new charts to dashboard pages
|
|
||||||
- 79bd867: Add new form layout page
|
|
||||||
|
|
||||||
### Patch Changes
|
|
||||||
|
|
||||||
- cac5d92: Update illustrations to v1.7
|
|
||||||
- f94b153: Add SRI hashes to scripts and styles
|
|
||||||
- c127d65: Fix colour picker preview page not displaying correctly
|
|
||||||
- b6e9b18: Update icons to v3.31.0
|
|
||||||
- 8850f61: Enhance pagination component with new styles
|
|
||||||
- 9910dd0: Add "text features" menu item
|
|
||||||
- 638f36c: Refactor SCSS variable names for shadows
|
|
||||||
- 0d501e9: Correct `aria-label` of app menu link
|
|
||||||
- 3a02ef9: Fix some marketing site rows overflowing on mobile
|
|
||||||
- fd0fd47: Improve card footer layout and enhance entry display format in invoices
|
|
||||||
- 74e5d26: Fix color badge in navbar menu
|
|
||||||
- 72a1d67: Add clipboard functionality to Tabler documentation
|
|
||||||
- bb617b8: Fix colour swatches on small screens
|
|
||||||
- d73d78e: Add missing `tw` entry in `flags.json`
|
|
||||||
- 19a3d20: Delete missing demo RTL style
|
|
||||||
- b5e2f54: Enhance dropdown components for better accessibility
|
|
||||||
- a41c956: Remove unnecessary `!important` from body padding
|
|
||||||
- e675389: Fix missing border-radius to `.card-header-tabs`
|
|
||||||
- 9007e73: Fix FAQ accordion structure
|
|
||||||
|
|
||||||
## 1.2.0
|
|
||||||
|
|
||||||
### Minor Changes
|
|
||||||
|
|
||||||
- c59bc9d: Add gradient background utilities
|
|
||||||
- f9e4da2: Add new apps card with brand icons in navbar
|
|
||||||
- 92a3afe: Replaced TinyMCE with HugeRTE to address license violation
|
|
||||||
- 199f39a: Update Bootstrap to version 5.3.5
|
|
||||||
- 9bbcb99: Add theme settings wizard
|
|
||||||
- b17b488: Add steps light colors
|
|
||||||
- 215eaa4: Add Turbo library integration
|
|
||||||
|
|
||||||
### Patch Changes
|
|
||||||
|
|
||||||
- aea3b0a: Rollback accordion component structure
|
|
||||||
- 3fc7b84: Add space between page numbers in pagination
|
|
||||||
- 2f8a372: Add Bootstrap components to Tabler JS
|
|
||||||
- 9fceadd: Fix tooltip colors in vector maps
|
|
||||||
- 44250db: Update avatar size variable to support list size configuration
|
|
||||||
- be1f3d1: Fix broken shape in South Korea flag
|
|
||||||
- c20d076: Refactor `border-radius` in components to use CSS variables
|
|
||||||
- 042e50f: Update disabled color variables in navbars
|
|
||||||
- 473fa38: Apply border radius to `tom-select` on focus
|
|
||||||
- 8646192: Add avatars page with various demos of avatars
|
|
||||||
- 922bb03: Minor spelling and grammar improvements to emails docs
|
|
||||||
- 44250db: Update avatar size variable to support list size configuration
|
|
||||||
- ddcd3a7: Refactor SCSS for alerts and close button styles
|
|
||||||
- e3d68d6: Fix `autosize` and `input mask` plugins to use window scope
|
|
||||||
- 4846828: Fix scrollbar color mixin to use body color variable
|
|
||||||
- 6b6617a: Improve README
|
|
||||||
- 94bea00: Make scrollbar track transparent
|
|
||||||
- e14e492: Fix scrollbar jumps when content is higher than screen
|
|
||||||
- 6d6d1bd: Add responsive font size for form controls on mobile devices
|
|
||||||
- 6c566cf: Add new advanced table example
|
|
||||||
|
|
||||||
## 1.1.1
|
|
||||||
|
|
||||||
### Patch Changes
|
|
||||||
|
|
||||||
- f29c911: Fix Documentation structure
|
|
||||||
|
|
||||||
## 1.1.0
|
|
||||||
|
|
||||||
### Minor Changes
|
|
||||||
|
|
||||||
- a2640e2: Add Playwright configuration and visual regression tests
|
|
||||||
- d3ae77c: Enable `scrollSpy` in `countup` module
|
|
||||||
- bd3d959: Refactor SCSS files to replace divide function with calc
|
|
||||||
- cb278c7: Add Segmented Control component
|
|
||||||
- b47725d: Add new text features page with mentions: user, color and app.
|
|
||||||
- b4b4d1a: Add Scroll Spy page
|
|
||||||
- 9cd5327: Update border radius variables for consistency across components
|
|
||||||
- 4376968: Add Signature Pad feature and signatures page
|
|
||||||
- f95f250: Update color utility classes and replace background colors in pricing table
|
|
||||||
- eaa7f81: Refactored the project into a monorepo, removed Gulp, and introduced a new, more efficient build process.
|
|
||||||
- ea14462: Add documentation for segmented control component
|
|
||||||
- 1edaff4: Add new payment provider (Troy)
|
|
||||||
- edbaa1e: Add selectable table functionality with active background color
|
|
||||||
- 378fba8: Refactor badge styles, remove Bootstrap styles
|
|
||||||
- f3c409f: Refactor alert component styles and markup, remove Bootstrap styles
|
|
||||||
- c240b5a: Refactor accordion component styles and markup, remove Bootstrap styles
|
|
||||||
|
|
||||||
### Patch Changes
|
|
||||||
|
|
||||||
- 687267d: Fix overflow of `label` in a `floating-input`
|
|
||||||
- 06b1dec: Fix size of `apexcharts` tooltip marker
|
|
||||||
- afd0700: Fix apexcharts heatmap example in docs
|
|
||||||
- 78383ef: Fix negative margins in `.navbar-bordered` variant
|
|
||||||
- 11f4487: Use the full license agreement for illustrations in docs
|
- 11f4487: Use the full license agreement for illustrations in docs
|
||||||
- b28ce9f: Fix vertical alignment in single page and error layouts
|
|
||||||
- 24b944c: Fix `.avatar-upload` double borders
|
|
||||||
- ca4ba14: Fixes navbar styles with new hover effects and color variables
|
|
||||||
|
|
||||||
## 1.0.0 - 2025-01-28
|
## 1.0.0 - 2025-01-28
|
||||||
|
|
||||||
@@ -150,8 +22,8 @@
|
|||||||
- be14607: Add new color picker component using `coloris.js` library
|
- be14607: Add new color picker component using `coloris.js` library
|
||||||
- d046570: Update Tabler Icons to version 2.23 with 18 new icons added
|
- d046570: Update Tabler Icons to version 2.23 with 18 new icons added
|
||||||
- 5488c50: New page with payment providers: `payment-providers.html`
|
- 5488c50: New page with payment providers: `payment-providers.html`
|
||||||
- 5488c50: Add support for new payment providers: 2c2p, Adyen, Affirm, Alipay Plus, Allegro Pay, Amazon Pay, Apple Pay, Autopay, Binance USD, Bkash, Cash App, Chime, EasyPaisa, Ethereum, Google Pay, HubSpot, iDeal, Litecoin, Mercado Pago, MetaMask, MoneyGram, OpenSea, Payconiq, Payka, Payline, PayPo, Paysafe, Poli,
|
- 5488c50: Add support for new payment providers: 2c2p, Adyen, Affirm, Alipay Plus, Allegro Pay, Amazon Pay, Apple Pay, Autopay, Binance USD, Bkash, Cash App, Chime, EasyPaisa, Ethereum, Google Pay, HubSpot, iDeal, Litecoin, Mercado Pago,
|
||||||
Revolut Pay, Samsung Pay, Shop Pay, Solana, Spingo, Stax, Tether, True USD, Venmo, WeChat Pay, Wise, Zelle
|
MetaMask, MoneyGram, OpenSea, Payconiq, Payka, Payline, PayPo, Paysafe, Poli, Revolut Pay, Samsung Pay, Shop Pay, Solana, Spingo, Stax, Tether, True USD, Venmo, WeChat Pay, Wise, Zelle
|
||||||
|
|
||||||
### Patch Changes
|
### Patch Changes
|
||||||
|
|
||||||
213
README.md
213
README.md
@@ -1,5 +1,5 @@
|
|||||||
<p align="center">
|
<p align="center">
|
||||||
<a href="https://github.com/tabler/tabler"><img src="https://raw.githubusercontent.com/tabler/tabler/refs/heads/dev/shared/static/logo.svg" alt="A premium and open source dashboard template with a responsive and high-quality UI." width="300"></a><br><br>
|
<a href="https://github.com/tabler/tabler"><img src="https://raw.githubusercontent.com/tabler/tabler/dev/src/static/logo.svg" alt="A premium and open source dashboard template with a responsive and high-quality UI." width="300"></a><br><br>
|
||||||
A premium and open source dashboard template with a responsive and high-quality UI.
|
A premium and open source dashboard template with a responsive and high-quality UI.
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
@@ -15,12 +15,12 @@ A premium and open source dashboard template with a responsive and high-quality
|
|||||||
|
|
||||||
## Sponsors
|
## Sponsors
|
||||||
|
|
||||||
**If you want to support our project and help us grow it, you can [become a sponsor on GitHub](https://github.com/sponsors/codecalm) or just [donate on PayPal](https://paypal.me/codecalm) :)**
|
**If you want to support our project and help me grow it, you can [become a sponsor on GitHub](https://github.com/sponsors/codecalm) or just [donate on PayPal](https://paypal.me/codecalm) :)**
|
||||||
|
|
||||||
<p align="center">
|
<p align="center">
|
||||||
<a href="https://github.com/sponsors/codecalm">
|
<a href="https://github.com/sponsors/codecalm">
|
||||||
<img src="https://cdn.jsdelivr.net/gh/tabler/sponsors@latest/sponsors.svg" alt="Tabler sponsors">
|
<img src="https://cdn.jsdelivr.net/gh/tabler/sponsors@latest/sponsors.svg" alt="Tabler sponsors">
|
||||||
</a>
|
</a>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
## Testing
|
## Testing
|
||||||
@@ -28,24 +28,21 @@ A premium and open source dashboard template with a responsive and high-quality
|
|||||||
<p align="center">Browser testing via:</p>
|
<p align="center">Browser testing via:</p>
|
||||||
|
|
||||||
<p align="center">
|
<p align="center">
|
||||||
<a href="https://www.lambdatest.com/" target="_blank">
|
<a href="https://www.lambdatest.com/" target="_blank">
|
||||||
<picture>
|
<picture>
|
||||||
<source media="(prefers-color-scheme: dark)" srcset="https://github.com/user-attachments/assets/14dd2a0a-bafe-436e-a6cb-29636278c781">
|
<source media="(prefers-color-scheme: dark)" srcset="https://github.com/user-attachments/assets/14dd2a0a-bafe-436e-a6cb-29636278c781">
|
||||||
<source media="(prefers-color-scheme: light)" srcset="https://github.com/user-attachments/assets/d3dede5a-d702-47c3-bb66-4d887948ed83">
|
<source media="(prefers-color-scheme: light)" srcset="https://github.com/user-attachments/assets/d3dede5a-d702-47c3-bb66-4d887948ed83">
|
||||||
<img src="https://github.com/user-attachments/assets/d3dede5a-d702-47c3-bb66-4d887948ed83" alt="labmdatest" width="296">
|
<img src="https://github.com/user-attachments/assets/d3dede5a-d702-47c3-bb66-4d887948ed83" alt="Tabler Icons preview" width="296">
|
||||||
</picture>
|
</picture>
|
||||||
</a>
|
</a>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
## 🔎 Preview
|
## 🔎 Preview
|
||||||
|
|
||||||
Tabler is fully responsive and compatible with all modern browsers. Thanks to its modern and user-friendly design you can create a fully functional interface that users will love! Choose the layouts and components you need and customize them to make your design consistent and eye-catching. Every component has been created with attention to detail to make your interface beautiful! <a href="https://preview.tabler.io">Show me a demo</a>
|
Tabler is fully responsive and compatible with all modern browsers. Thanks to its modern and user-friendly design you can create a fully functional interface that users will love! Choose the layouts and components you need and customize them to make your design consistent and eye-catching. Every component has been created with attention to detail to make your interface beautiful! <a href="https://preview.tabler.io">Show me a demo</a>
|
||||||
|
|
||||||
<p align="center">
|
<a href="https://preview.tabler.io" target="_blank"><img src="https://raw.githubusercontent.com/tabler/tabler/dev/src/static/tabler-preview.png" alt="Tabler preview"></a>
|
||||||
<a href="https://preview.tabler.io" target="_blank">
|
|
||||||
<img src="https://raw.githubusercontent.com/tabler/tabler/dev/shared/static/tabler-preview.png" alt="Tabler Preview">
|
|
||||||
</a>
|
|
||||||
</p>
|
|
||||||
|
|
||||||
## 🚀 Features
|
## 🚀 Features
|
||||||
|
|
||||||
@@ -56,30 +53,110 @@ We've created this admin panel for everyone who wants to create templates based
|
|||||||
* **HTML5 & CSS3:** We use only modern web technologies, such as HTML5 and CSS3. Our theme includes some subtle CSS3 animations, which will help you attract attention.
|
* **HTML5 & CSS3:** We use only modern web technologies, such as HTML5 and CSS3. Our theme includes some subtle CSS3 animations, which will help you attract attention.
|
||||||
* **Clean Code:** We followed Bootstrap’s guidelines carefully to make your integration as easy as possible. All code is handwritten and W3C valid.
|
* **Clean Code:** We followed Bootstrap’s guidelines carefully to make your integration as easy as possible. All code is handwritten and W3C valid.
|
||||||
* **Demo pages**: Tabler features over 20 individual pages using various components, which gives you the freedom to choose and combine. All components can vary in color and styling that you can easily modify using Sass. Sky is the limit!
|
* **Demo pages**: Tabler features over 20 individual pages using various components, which gives you the freedom to choose and combine. All components can vary in color and styling that you can easily modify using Sass. Sky is the limit!
|
||||||
|
* **Single Page Application versions:** [Tabler React](https://github.com/tabler/tabler-react) has React components for Tabler.
|
||||||
|
|
||||||
## 📖 Documentation
|
## 📖 Documentation
|
||||||
|
|
||||||
The documentation is available at https://docs.tabler.io/
|
Documentation is available as a part of Tabler preview: https://tabler.io/docs/
|
||||||
|
|
||||||
|
To run the documentation site locally, follow instructions in the [Documentation README](https://github.com/tabler/tabler/blob/dev/site/README.md).
|
||||||
|
|
||||||
## 🪴 Project Activity
|
## 🪴 Project Activity
|
||||||
|
|
||||||
<p align="center">
|

|
||||||
<img src="https://repobeats.axiom.co/api/embed/61d1db34446967b0848af68198a392067e0f5870.svg" alt="Repobeats analytics image" />
|
|
||||||
</p>
|
## 💕 Sponsor Tabler
|
||||||
|
|
||||||
|
<a href="https://github.com/sponsors/codecalm" target="_blank"><img src="/src/static/sponsor-banner-readme.png?raw=true" alt="Sponsor Tabler" /></a>
|
||||||
|
|
||||||
|
|
||||||
|
### Sponsors
|
||||||
|
|
||||||
|
Support this project by becoming a sponsor. Your logo will show up in this README with a link to your website. [Become a sponsor!](https://opencollective.com/tabler#sponsor)
|
||||||
|
|
||||||
|
<a href="https://opencollective.com/tabler/tiers/sponsor/0/website" target="_blank"><img src="https://opencollective.com/tabler/tiers/sponsor/0/avatar.svg" /></a>
|
||||||
|
<a href="https://opencollective.com/tabler/tiers/sponsor/1/website" target="_blank"><img src="https://opencollective.com/tabler/tiers/sponsor/1/avatar.svg" /></a>
|
||||||
|
<a href="https://opencollective.com/tabler/tiers/sponsor/2/website" target="_blank"><img src="https://opencollective.com/tabler/tiers/sponsor/2/avatar.svg" /></a>
|
||||||
|
<a href="https://opencollective.com/tabler/tiers/sponsor/3/website" target="_blank"><img src="https://opencollective.com/tabler/tiers/sponsor/3/avatar.svg" /></a>
|
||||||
|
<a href="https://opencollective.com/tabler/tiers/sponsor/4/website" target="_blank"><img src="https://opencollective.com/tabler/tiers/sponsor/4/avatar.svg" /></a>
|
||||||
|
<a href="https://opencollective.com/tabler/tiers/sponsor/5/website" target="_blank"><img src="https://opencollective.com/tabler/tiers/sponsor/5/avatar.svg" /></a>
|
||||||
|
<a href="https://opencollective.com/tabler/tiers/sponsor/6/website" target="_blank"><img src="https://opencollective.com/tabler/tiers/sponsor/6/avatar.svg" /></a>
|
||||||
|
<a href="https://opencollective.com/tabler/tiers/sponsor/7/website" target="_blank"><img src="https://opencollective.com/tabler/tiers/sponsor/7/avatar.svg" /></a>
|
||||||
|
<a href="https://opencollective.com/tabler/tiers/sponsor/8/website" target="_blank"><img src="https://opencollective.com/tabler/tiers/sponsor/8/avatar.svg" /></a>
|
||||||
|
<a href="https://opencollective.com/tabler/tiers/sponsor/9/website" target="_blank"><img src="https://opencollective.com/tabler/tiers/sponsor/9/avatar.svg" /></a>
|
||||||
|
|
||||||
|
## 📦 Setup environment
|
||||||
|
|
||||||
|
To use our build system and run our documentation locally, you'll need a copy of Tabler's source files. Follow the steps below:
|
||||||
|
|
||||||
|
1. [Install Node.js](https://nodejs.org/download/), which we use to manage our dependencies.
|
||||||
|
2. Navigate to the root `/tabler` directory and run `pnpm install` to install our local dependencies listed in `package.json`.
|
||||||
|
|
||||||
|
**OSX users**:
|
||||||
|
|
||||||
|
```pnpm install```
|
||||||
|
|
||||||
|
and then
|
||||||
|
|
||||||
|
```npm run start```
|
||||||
|
|
||||||
|
|
||||||
|
**Windows users**:
|
||||||
|
|
||||||
|
[Install Git](https://git-scm.com/download/win) in `C:\Program Files\git\bin` directory and run `npm config set script-shell "C:\\Program Files\\git\\bin\\bash.exe"` to change the default shell.
|
||||||
|
|
||||||
|
Once you complete the setup, you'll be able to run the various commands provided from the command line.
|
||||||
|
|
||||||
|
|
||||||
|
## Build locally
|
||||||
|
|
||||||
|
You need to have `pnpm` and `bundler` installed.
|
||||||
|
|
||||||
|
1. From the root `/tabler` directory, run installation in the command line: `pnpm install`
|
||||||
|
2. Then execute `pnpm run start` to start up the application stack.
|
||||||
|
3. Open [http://localhost:3000](http://localhost:3000) in your browser, and voilà.
|
||||||
|
4. Any change in the `/src` directory will build the application and refresh the page.
|
||||||
|
|
||||||
|
**Note**:
|
||||||
|
Run `pnpm run build` for reforms a one off build application without refresh.
|
||||||
|
Open [http://localhost:3001](http://localhost:3001) to configure the Web server.
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
### Package Managers
|
Tabler is distributed via npm.
|
||||||
|
|
||||||
Tabler is distributed via npm. You can install it with this or your preferred JavaScript package manager:
|
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
npm install --save @tabler/core
|
npm install --save @tabler/core
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Running with Docker
|
||||||
|
|
||||||
|
**Plain Docker**
|
||||||
|
|
||||||
|
If you don't want to install node/npm and the dependencies on your local environment, you can use the provided Dockerfile to build a docker image.
|
||||||
|
This Dockerfile is provided as an example to spin-up a container running Tabler.
|
||||||
|
|
||||||
|
Example of how to use this image:
|
||||||
|
|
||||||
|
1. Build the tabler image : `docker build -t tabler .`
|
||||||
|
2. Run the tabler image while mounting the `src` directory as well as the `_config.yml` file into the container.
|
||||||
|
|
||||||
|
Don't forget to expose the port 3000 so you can browse the website locally.
|
||||||
|
You can also expose the port 3001 to have access to BrowserSync
|
||||||
|
|
||||||
|
```sh
|
||||||
|
docker run -p 3000:3000 -p 3001:3001 -v $(pwd)/src:/app/src -v $(pwd)/_config.yml:/app/_config.yml tabler
|
||||||
|
```
|
||||||
|
|
||||||
|
Now open your browser to [http://localhost:3000](http://localhost:3000). Edit anything in the `src/` folder and watch your browser refresh the page after it has been rebuilt.
|
||||||
|
|
||||||
|
**Docker Compose**
|
||||||
|
|
||||||
|
You can also use the docker compose config from this repo. Use `docker compose build && docker compose up` or `docker compose up --build` to build and start the container. Edit anything in the `src/` folder the same way as with plain docker and access the same URLs and ports in your browser.
|
||||||
|
|
||||||
### CDN support
|
### CDN support
|
||||||
|
|
||||||
All files included in `@tabler/core` npm package are also available over a CDN.
|
All files included in `@tabler/core` npm package are available over a CDN.
|
||||||
|
|
||||||
#### Javascript
|
#### Javascript
|
||||||
|
|
||||||
@@ -93,84 +170,24 @@ All files included in `@tabler/core` npm package are also available over a CDN.
|
|||||||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@tabler/core@latest/dist/css/tabler.min.css">
|
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@tabler/core@latest/dist/css/tabler.min.css">
|
||||||
```
|
```
|
||||||
|
|
||||||
## Building locally
|
## Feature requests
|
||||||
|
|
||||||
To build a copy of Tabler locally, you have two options. You can either set up your device directly with the development tools required to build Tabler, or if you would prefer not to install all the development dependencies directly onto your device, you can use a Dockerfile that Tabler provides to build a docker image. Instructions follow below.
|
https://tabler.canny.io/feature-requests
|
||||||
|
|
||||||
### First steps: Downloading the Tabler source files
|
|
||||||
|
|
||||||
With either method, the first thing you'll want to do is download a copy of the Tabler source files to your device.
|
|
||||||
|
|
||||||
#### From the Tabler GitHub releases page
|
|
||||||
|
|
||||||
If you don't want to edit the source code once you've downloaded it, and aren't interested in merging future project updates into your copy, you can just download the source files straight from the [Tabler releases on GitHub](https://github.com/tabler/tabler/releases) and extract the contents to a directory called `tabler`.
|
|
||||||
|
|
||||||
#### Cloning with Git
|
|
||||||
|
|
||||||
If you **do** wish to edit the source code after downloading it, for example to contribute changes back to the Tabler project, you'll want to do this by cloning it with Git:
|
|
||||||
1. If you don't have Git installed on your device, download and install it. You can find instructions at [https://git-scm.com/downloads](https://git-scm.com/downloads).
|
|
||||||
2. (Optional) **Windows users:** you could optionally install Git in the `C:\Program Files\git\bin` directory and run `npm config set script-shell "C:\\Program Files\\git\\bin\\bash.exe"` to change the default shell.
|
|
||||||
3. Clone the Tabler project into a folder on your device. Instructions can be found at [cloning a repository](https://docs.github.com/en/repositories/creating-and-managing-repositories/cloning-a-repository).
|
|
||||||
|
|
||||||
### Installing and running development tools directly
|
|
||||||
|
|
||||||
1. [Install Node.js](https://nodejs.org/download/), which we use to manage our dependencies.
|
|
||||||
2. [Install pnpm](https://pnpm.io/installation) (We recommend either by [Using Corepack](https://pnpm.io/installation#using-corepack) or by [Using npm](https://pnpm.io/installation#using-npm))
|
|
||||||
3. From the root `/tabler` directory where you downloaded the Tabler source files, run installation on the command line:
|
|
||||||
```sh
|
|
||||||
pnpm install
|
|
||||||
```
|
|
||||||
4. Then execute the following to start up the application stack:
|
|
||||||
```sh
|
|
||||||
pnpm run start
|
|
||||||
```
|
|
||||||
5. Open [http://localhost:3000](http://localhost:3000) to view the preview website in your browser, or [http://localhost:3010](http://localhost:3010) to view the documentation website - and voilà.
|
|
||||||
Changes to most of the source files of Tabler core, preview and docs will rebuild the application and refresh the page.
|
|
||||||
|
|
||||||
**Note**:
|
|
||||||
If you wish to perform a one-off build without auto-refresh on any changes, you can run:
|
|
||||||
```sh
|
|
||||||
pnpm run build
|
|
||||||
```
|
|
||||||
You can open [http://localhost:3001](http://localhost:3001) to configure the Web server.
|
|
||||||
|
|
||||||
|
|
||||||
### Installing and running development tools with Docker
|
|
||||||
|
|
||||||
**Plain Docker**
|
|
||||||
|
|
||||||
Here is an example of how to use this image:
|
|
||||||
|
|
||||||
1. From the root `/tabler` directory where you downloaded the Tabler source files, build the tabler image:
|
|
||||||
```sh
|
|
||||||
docker build -t tabler .
|
|
||||||
```
|
|
||||||
2. Run the tabler image. The following command mounts the `src` directory into the container, exposes port 3000 to browse the website locally, and exposes port 3001 to automatically sync changes:
|
|
||||||
```sh
|
|
||||||
docker run -p 3000:3000 -p 3001:3001 -v $(pwd)/src:/app/src tabler
|
|
||||||
```
|
|
||||||
3. Open your browser to [http://localhost:3000](http://localhost:3000). Edit anything in the `src/` folder and watch your browser refresh the page after it has been rebuilt.
|
|
||||||
|
|
||||||
**Docker Compose**
|
|
||||||
|
|
||||||
You can also use the docker compose config from this repo. From the root `/tabler` directory where you downloaded the Tabler source files, use `docker compose build && docker compose up` or `docker compose up --build` to build and start the container. Edit anything in the `src/` folder the same way as with plain docker and access the same URLs and ports in your browser.
|
|
||||||
|
|
||||||
## Bugs and feature requests
|
## Bugs and feature requests
|
||||||
|
|
||||||
Found a bug or have a feature request? [Please open a new issue](https://github.com/tabler/tabler/issues/new).
|
Found a bug or have a feature request? [Please open a new issue](https://github.com/tabler/tabler/issues/new).
|
||||||
|
|
||||||
|
|
||||||
## 🤓 Creators
|
## 🤓 Creators
|
||||||
|
|
||||||
**Paweł Kuna**
|
**Paweł Kuna**
|
||||||
|
|
||||||
- <https://x.com/codecalm>
|
- <https://twitter.com/codecalm>
|
||||||
- <https://github.com/codecalm>
|
- <https://github.com/codecalm>
|
||||||
- <https://codecalm.net>
|
- <https://codecalm.net>
|
||||||
|
|
||||||
**Bartłomiej Gawęda**
|
|
||||||
|
|
||||||
- <https://x.com/B_Gaweda>
|
|
||||||
- <https://github.com/BG-Software-BG>
|
|
||||||
|
|
||||||
## 👨🚀 Contributors
|
## 👨🚀 Contributors
|
||||||
|
|
||||||
@@ -178,11 +195,25 @@ This project exists thanks to all the people who contribute.
|
|||||||
|
|
||||||
<img src="https://opencollective.com/tabler/contributors.svg?width=890&button=false" />
|
<img src="https://opencollective.com/tabler/contributors.svg?width=890&button=false" />
|
||||||
|
|
||||||
## Social media
|
## 🌸 Backers
|
||||||
|
|
||||||
Stay up to date by joining our community on <a href="https://x.com/tabler_io" >X</a> and <a href="https://www.facebook.com/tabler.io">Facebook</a>
|
Thank you to all our backers! 🙏 [Become a backer](https://opencollective.com/tabler#backer)
|
||||||
|
|
||||||
|
<a href="https://opencollective.com/tabler#backers" target="_blank"><img src="https://opencollective.com/tabler/tiers/backer.svg?width=890&button=false" /></a>
|
||||||
|
|
||||||
## License
|
## License
|
||||||
|
|
||||||
See the [LICENSE](https://github.com/tabler/tabler/blob/master/LICENSE) file.
|
See the [LICENSE](https://github.com/tabler/tabler/blob/master/LICENSE) file.
|
||||||
|
|
||||||
|
## Contributors ✨
|
||||||
|
|
||||||
|
Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/docs/en/emoji-key)):
|
||||||
|
|
||||||
|
<!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section -->
|
||||||
|
<!-- prettier-ignore-start -->
|
||||||
|
<!-- markdownlint-disable -->
|
||||||
|
<!-- markdownlint-restore -->
|
||||||
|
<!-- prettier-ignore-end -->
|
||||||
|
<!-- ALL-CONTRIBUTORS-LIST:END -->
|
||||||
|
|
||||||
|
This project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome!
|
||||||
|
|||||||
@@ -1,46 +0,0 @@
|
|||||||
#!/usr/bin/env node
|
|
||||||
|
|
||||||
'use strict'
|
|
||||||
|
|
||||||
import { readFileSync, writeFileSync } from 'node:fs';
|
|
||||||
import { join, dirname, basename } from 'node:path';
|
|
||||||
import { fileURLToPath } from 'node:url'
|
|
||||||
import { sync } from 'glob';
|
|
||||||
import banner from '../../shared/banner/index.mjs';
|
|
||||||
|
|
||||||
const __dirname = dirname(fileURLToPath(import.meta.url))
|
|
||||||
|
|
||||||
const styles = sync(join(__dirname, '..', 'dist', 'css', '*.css'))
|
|
||||||
|
|
||||||
const plugins = {
|
|
||||||
'tabler-flags': 'Flags',
|
|
||||||
'tabler-flags.rtl': 'Flags RTL',
|
|
||||||
'tabler-marketing': 'Marketing',
|
|
||||||
'tabler-marketing.rtl': 'Marketing RTL',
|
|
||||||
'tabler-payments': 'Payments',
|
|
||||||
'tabler-payments.rtl': 'Payments RTL',
|
|
||||||
'tabler-socials': 'Socials',
|
|
||||||
'tabler-socials.rtl': 'Socials RTL',
|
|
||||||
'tabler-vendors': 'Vendors',
|
|
||||||
'tabler-vendors.rtl': 'Vendors RTL',
|
|
||||||
}
|
|
||||||
|
|
||||||
styles.forEach((file, i) => {
|
|
||||||
const content = readFileSync(file, 'utf8')
|
|
||||||
const filename = basename(file)
|
|
||||||
const pluginKey = Object.keys(plugins).find(plugin => filename.includes(plugin))
|
|
||||||
const plugin = plugins[pluginKey]
|
|
||||||
const regex = /^(@charset ['"][a-zA-Z0-9-]+['"];?)\n?/i
|
|
||||||
|
|
||||||
let newContent = ''
|
|
||||||
|
|
||||||
if (content.match(regex)) {
|
|
||||||
newContent = content.replace(regex, (m, m1) => {
|
|
||||||
return `${m1}\n${banner(plugin)}\n`
|
|
||||||
})
|
|
||||||
} else {
|
|
||||||
newContent = `${banner(plugin)}\n${content}`
|
|
||||||
}
|
|
||||||
|
|
||||||
writeFileSync(file, newContent, 'utf8')
|
|
||||||
})
|
|
||||||
@@ -1,33 +0,0 @@
|
|||||||
#!/usr/bin/env node
|
|
||||||
|
|
||||||
'use strict'
|
|
||||||
|
|
||||||
import { existsSync, mkdirSync, lstatSync } from 'fs'
|
|
||||||
import { emptyDirSync, copySync } from 'fs-extra/esm'
|
|
||||||
import libs from '../libs.json' with { type: 'json' }
|
|
||||||
import { fileURLToPath } from 'url'
|
|
||||||
import { join, dirname } from 'node:path';
|
|
||||||
|
|
||||||
const __dirname = dirname(fileURLToPath(import.meta.url))
|
|
||||||
|
|
||||||
emptyDirSync(join(__dirname, '..', 'dist/libs'))
|
|
||||||
|
|
||||||
for(const name in libs) {
|
|
||||||
const { npm } = libs[name]
|
|
||||||
|
|
||||||
if (npm) {
|
|
||||||
const from = join(__dirname, '..', `node_modules/${npm}`)
|
|
||||||
const to = join(__dirname, '..', `dist/libs/${npm}`)
|
|
||||||
|
|
||||||
// create dir in dist/libs
|
|
||||||
if (!existsSync(to)) {
|
|
||||||
mkdirSync(to, { recursive: true })
|
|
||||||
}
|
|
||||||
|
|
||||||
copySync(from, to, {
|
|
||||||
dereference: true,
|
|
||||||
})
|
|
||||||
|
|
||||||
console.log(`Successfully copied ${npm}`)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,107 +0,0 @@
|
|||||||
const crypto = require('node:crypto');
|
|
||||||
const fs = require('node:fs');
|
|
||||||
const path = require('node:path');
|
|
||||||
const sh = require('shelljs');
|
|
||||||
|
|
||||||
sh.config.fatal = true
|
|
||||||
|
|
||||||
const configFile = path.join(__dirname, '../../shared/data/sri.json')
|
|
||||||
|
|
||||||
const files = [
|
|
||||||
{
|
|
||||||
file: 'dist/css/tabler.min.css',
|
|
||||||
configPropertyName: 'css'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
file: 'dist/css/tabler.rtl.min.css',
|
|
||||||
configPropertyName: 'css-rtl'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
file: 'dist/css/tabler-flags.min.css',
|
|
||||||
configPropertyName: 'css-flags'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
file: 'dist/css/tabler-flags.rtl.min.css',
|
|
||||||
configPropertyName: 'css-flags-rtl'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
file: 'dist/css/tabler-marketing.min.css',
|
|
||||||
configPropertyName: 'css-marketing'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
file: 'dist/css/tabler-marketing.rtl.min.css',
|
|
||||||
configPropertyName: 'css-marketing-rtl'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
file: 'dist/css/tabler-payments.min.css',
|
|
||||||
configPropertyName: 'css-payments'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
file: 'dist/css/tabler-payments.rtl.min.css',
|
|
||||||
configPropertyName: 'css-payments-rtl'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
file: 'dist/css/tabler-props.min.css',
|
|
||||||
configPropertyName: 'css-props'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
file: 'dist/css/tabler-props.rtl.min.css',
|
|
||||||
configPropertyName: 'css-props-rtl'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
file: 'dist/css/tabler-themes.min.css',
|
|
||||||
configPropertyName: 'css-themes'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
file: 'dist/css/tabler-themes.rtl.min.css',
|
|
||||||
configPropertyName: 'css-themes-rtl'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
file: 'dist/css/tabler-socials.min.css',
|
|
||||||
configPropertyName: 'css-socials'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
file: 'dist/css/tabler-socials.rtl.min.css',
|
|
||||||
configPropertyName: 'css-socials-rtl'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
file: 'dist/css/tabler-vendors.min.css',
|
|
||||||
configPropertyName: 'css-vendors'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
file: 'dist/css/tabler-vendors.rtl.min.css',
|
|
||||||
configPropertyName: 'css-vendors-rtl'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
file: 'dist/js/tabler.min.js',
|
|
||||||
configPropertyName: 'js'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
file: 'dist/js/tabler-theme.min.js',
|
|
||||||
configPropertyName: 'js-theme'
|
|
||||||
},
|
|
||||||
// {
|
|
||||||
// file: 'dist/preview/css/demo.min.css',
|
|
||||||
// configPropertyName: 'demo-css'
|
|
||||||
// },
|
|
||||||
// {
|
|
||||||
// file: 'dist/preview/js/demo.min.js',
|
|
||||||
// configPropertyName: 'demo-js'
|
|
||||||
// },
|
|
||||||
]
|
|
||||||
|
|
||||||
for (const { file, configPropertyName } of files) {
|
|
||||||
fs.readFile(path.join(__dirname, '..', file), 'utf8', (error, data) => {
|
|
||||||
if (error) {
|
|
||||||
throw error
|
|
||||||
}
|
|
||||||
|
|
||||||
const algorithm = 'sha384'
|
|
||||||
const hash = crypto.createHash(algorithm).update(data, 'utf8').digest('base64')
|
|
||||||
const integrity = `${algorithm}-${hash}`
|
|
||||||
|
|
||||||
console.log(`${configPropertyName}: ${integrity}`)
|
|
||||||
|
|
||||||
sh.sed('-i', new RegExp(`^(\\s+"${configPropertyName}":\\s+["'])\\S*(["'])`), `$1${integrity}$2`, configFile)
|
|
||||||
})
|
|
||||||
}
|
|
||||||
@@ -1,15 +0,0 @@
|
|||||||
export default context => {
|
|
||||||
return {
|
|
||||||
map: {
|
|
||||||
inline: false,
|
|
||||||
annotation: true,
|
|
||||||
sourcesContent: true
|
|
||||||
},
|
|
||||||
plugins: {
|
|
||||||
autoprefixer: {
|
|
||||||
cascade: false
|
|
||||||
},
|
|
||||||
rtlcss: context.env === 'RTL'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,47 +0,0 @@
|
|||||||
import path from 'node:path'
|
|
||||||
import process from 'node:process'
|
|
||||||
import { fileURLToPath } from 'node:url'
|
|
||||||
import { babel } from '@rollup/plugin-babel'
|
|
||||||
import { nodeResolve } from '@rollup/plugin-node-resolve'
|
|
||||||
import replace from '@rollup/plugin-replace'
|
|
||||||
import banner from '../../shared/banner/index.mjs'
|
|
||||||
|
|
||||||
const __dirname = path.dirname(fileURLToPath(import.meta.url))
|
|
||||||
|
|
||||||
const ESM = process.env.ESM === 'true'
|
|
||||||
const THEME = process.env.THEME === 'true'
|
|
||||||
|
|
||||||
const external = []
|
|
||||||
const plugins = [
|
|
||||||
babel({
|
|
||||||
exclude: 'node_modules/**',
|
|
||||||
babelHelpers: 'bundled'
|
|
||||||
})
|
|
||||||
]
|
|
||||||
|
|
||||||
plugins.push(
|
|
||||||
replace({
|
|
||||||
'process.env.NODE_ENV': '"production"',
|
|
||||||
preventAssignment: true
|
|
||||||
}),
|
|
||||||
nodeResolve()
|
|
||||||
)
|
|
||||||
|
|
||||||
const destinationFile = `tabler${THEME ? '-theme' : ''}${ESM ? '.esm' : ''}`
|
|
||||||
const rollupConfig = {
|
|
||||||
input: path.resolve(__dirname, `../js/tabler${THEME ? '-theme' : ''}.js`),
|
|
||||||
output: {
|
|
||||||
banner: banner(),
|
|
||||||
file: path.resolve(__dirname, `../dist/js/${destinationFile}.js`),
|
|
||||||
format: ESM ? 'esm' : 'umd',
|
|
||||||
generatedCode: 'es2015'
|
|
||||||
},
|
|
||||||
external,
|
|
||||||
plugins
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!ESM) {
|
|
||||||
rollupConfig.output.name = `tabler${THEME ? '-theme' : ''}`
|
|
||||||
}
|
|
||||||
|
|
||||||
export default rollupConfig
|
|
||||||
@@ -1,42 +0,0 @@
|
|||||||
# Tabler Core
|
|
||||||
|
|
||||||
Tabler Core is a set of components and utilities for building web applications. It provides a collection of pre-designed components, such as buttons, forms, modals, and more, that can be easily customized and integrated into your projects.
|
|
||||||
|
|
||||||
## 🔎 Preview
|
|
||||||
|
|
||||||
Tabler is fully responsive and compatible with all modern browsers. Thanks to its modern and user-friendly design you can create a fully functional interface that users will love! Choose the layouts and components you need and customize them to make your design consistent and eye-catching. Every component has been created with attention to detail to make your interface beautiful!
|
|
||||||
|
|
||||||
<p align="center">
|
|
||||||
<a href="https://preview.tabler.io" target="_blank">
|
|
||||||
<img src="https://raw.githubusercontent.com/tabler/tabler/dev/shared/static/tabler-preview.png" alt="Tabler Preview">
|
|
||||||
</a>
|
|
||||||
</p>
|
|
||||||
|
|
||||||
## Installation
|
|
||||||
|
|
||||||
To install Tabler Core, you can use npm or yarn. Run one of the following commands in your terminal:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
npm install @tabler/core
|
|
||||||
```
|
|
||||||
|
|
||||||
or
|
|
||||||
|
|
||||||
```bash
|
|
||||||
pnpm add @tabler/core
|
|
||||||
```
|
|
||||||
|
|
||||||
## Sponsors
|
|
||||||
|
|
||||||
**If you want to support our project and help us grow it, you can [become a sponsor on GitHub](https://github.com/sponsors/codecalm) or just [donate on PayPal](https://paypal.me/codecalm) :)**
|
|
||||||
|
|
||||||
<p align="center">
|
|
||||||
<a href="https://github.com/sponsors/codecalm">
|
|
||||||
<img src="https://cdn.jsdelivr.net/gh/tabler/sponsors@latest/sponsors.svg" alt="Tabler sponsors">
|
|
||||||
</a>
|
|
||||||
</p>
|
|
||||||
|
|
||||||
|
|
||||||
## License
|
|
||||||
|
|
||||||
See the [LICENSE](https://github.com/tabler/tabler/blob/master/LICENSE) file.
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="15" fill="none"><path d="M0,0V15H20V0Z" fill="#f7fcff" fill-rule="evenodd"/><path d="M13.74,7.58a3.66,3.66,0,1,1-3.66-3.7A3.67,3.67,0,0,1,13.74,7.58Z" fill="#e31d1c" fill-rule="evenodd"/><path d="M6.47,6.93c.12.93.29,2,1.72,2.08a1.82,1.82,0,0,0,1.94-1.6,1.81,1.81,0,0,1,2.86-1,1.71,1.71,0,0,1,.74,1.35,3.64,3.64,0,0,1-1.84,3.08,3.73,3.73,0,0,1-4.16-.34A3.84,3.84,0,0,1,6.47,6.93Z" fill="#3d58db" fill-rule="evenodd"/><path d="M4.56,1.28l.57.52L2.48,4.89l-.57-.51Zm.94.84.58.52L3.52,5.69,3,5.17ZM7,3.48,6.44,3,3.88,6l.57.52L7,3.48Zm8.84-2.41-.57.51,1,1.16.57-.51Zm1.77,2.14L17,3.72l1,1.17.57-.52Zm-4.23,0L14,2.74l1,1.17-.57.51Zm2.34,1.62-.57.52,1,1.16.57-.51ZM14.37,2.39l.57-.51,2.77,3.36-.58.52ZM16.28,8.9l-.57-.52-1,1.17.57.52,1-1.17ZM14.6,11,14,10.44l-1,1.17.57.52,1-1.17ZM17.53,10l.58.52-1,1.17-.58-.52Zm-1,2.62-.58-.52-1,1.17.57.52ZM15,11.24l.58.51L14.51,13l-.58-.52Zm2.29-1.57-.58-.51-1,1.24.57.52ZM4,9.31l.58-.52,2.55,2.93-.57.51Zm.6,2.55.57-.51,1.08,1.18-.57.52ZM2.69,10.43,2.12,11l2.57,3,.57-.51Zm.41-.33.57-.52.94,1.1L4,11.19Z" fill="#272727" fill-rule="evenodd"/></svg>
|
|
||||||
|
Before Width: | Height: | Size: 1.1 KiB |
File diff suppressed because one or more lines are too long
|
Before Width: | Height: | Size: 5.4 KiB |
File diff suppressed because one or more lines are too long
|
Before Width: | Height: | Size: 5.4 KiB |
3
core/js/src/bootstrap.js
vendored
3
core/js/src/bootstrap.js
vendored
@@ -1,3 +0,0 @@
|
|||||||
export * as Popper from '@popperjs/core';
|
|
||||||
|
|
||||||
export { Dropdown, Tooltip, Popover, Tab, Toast } from 'bootstrap';
|
|
||||||
@@ -1,23 +0,0 @@
|
|||||||
const elements = document.querySelectorAll('[data-countup]');
|
|
||||||
|
|
||||||
if (elements.length) {
|
|
||||||
elements.forEach(function (element) {
|
|
||||||
let options = {};
|
|
||||||
try {
|
|
||||||
const dataOptions = element.getAttribute('data-countup') ? JSON.parse(element.getAttribute('data-countup')) : {};
|
|
||||||
options = Object.assign({
|
|
||||||
'enableScrollSpy': true
|
|
||||||
}, dataOptions);
|
|
||||||
|
|
||||||
} catch (error) {}
|
|
||||||
|
|
||||||
const value = parseInt(element.innerHTML, 10);
|
|
||||||
|
|
||||||
if (window.countUp && window.countUp.CountUp) {
|
|
||||||
const countUp = new window.countUp.CountUp(element, value, options);
|
|
||||||
if (!countUp.error) {
|
|
||||||
countUp.start();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
@@ -1,25 +0,0 @@
|
|||||||
// SortableJS plugin
|
|
||||||
// Initializes Sortable on elements marked with [data-sortable]
|
|
||||||
// Allows options via JSON in data attribute: data-sortable='{"animation":150}'
|
|
||||||
|
|
||||||
const sortableElements = document.querySelectorAll('[data-sortable]');
|
|
||||||
|
|
||||||
if (sortableElements.length) {
|
|
||||||
sortableElements.forEach(function (element) {
|
|
||||||
let options = {};
|
|
||||||
|
|
||||||
try {
|
|
||||||
const rawOptions = element.getAttribute('data-sortable');
|
|
||||||
options = rawOptions ? JSON.parse(rawOptions) : {};
|
|
||||||
} catch (e) {
|
|
||||||
// ignore invalid JSON
|
|
||||||
}
|
|
||||||
|
|
||||||
if (window.Sortable) {
|
|
||||||
// eslint-disable-next-line no-new
|
|
||||||
new window.Sortable(element, options);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
@@ -1,38 +0,0 @@
|
|||||||
/**
|
|
||||||
* demo-theme is specifically loaded right after the body and not deferred
|
|
||||||
* to ensure we switch to the chosen dark/light theme as fast as possible.
|
|
||||||
* This will prevent any flashes of the light theme (default) before switching.
|
|
||||||
*/
|
|
||||||
const themeConfig = {
|
|
||||||
"theme": "light",
|
|
||||||
"theme-base": "gray",
|
|
||||||
"theme-font": "sans-serif",
|
|
||||||
"theme-primary": "blue",
|
|
||||||
"theme-radius": "1",
|
|
||||||
"sidebar-position": "left",
|
|
||||||
"sidebar-behavior": "sticky",
|
|
||||||
"layout": "container",
|
|
||||||
}
|
|
||||||
|
|
||||||
const params = new Proxy(new URLSearchParams(window.location.search), {
|
|
||||||
get: (searchParams, prop) => searchParams.get(prop),
|
|
||||||
})
|
|
||||||
|
|
||||||
for (const key in themeConfig) {
|
|
||||||
const param = params[key]
|
|
||||||
let selectedValue
|
|
||||||
|
|
||||||
if (!!param) {
|
|
||||||
localStorage.setItem('tabler-' + key, param)
|
|
||||||
selectedValue = param
|
|
||||||
} else {
|
|
||||||
const storedTheme = localStorage.getItem('tabler-' + key)
|
|
||||||
selectedValue = storedTheme ? storedTheme : themeConfig[key]
|
|
||||||
}
|
|
||||||
|
|
||||||
if (selectedValue !== themeConfig[key]) {
|
|
||||||
document.documentElement.setAttribute('data-bs-' + key, selectedValue)
|
|
||||||
} else {
|
|
||||||
document.documentElement.removeAttribute('data-bs-' + key)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,28 +0,0 @@
|
|||||||
import "./src/autosize"
|
|
||||||
import "./src/countup"
|
|
||||||
import "./src/input-mask"
|
|
||||||
import "./src/dropdown"
|
|
||||||
import "./src/tooltip"
|
|
||||||
import "./src/popover"
|
|
||||||
import "./src/switch-icon"
|
|
||||||
import "./src/tab"
|
|
||||||
import "./src/toast"
|
|
||||||
import "./src/sortable"
|
|
||||||
|
|
||||||
export * as bootstrap from "bootstrap"
|
|
||||||
export * as tabler from "./src/tabler"
|
|
||||||
|
|
||||||
export {
|
|
||||||
Alert,
|
|
||||||
Modal,
|
|
||||||
Toast,
|
|
||||||
Tooltip,
|
|
||||||
Tab,
|
|
||||||
Button,
|
|
||||||
Carousel,
|
|
||||||
Collapse,
|
|
||||||
Dropdown,
|
|
||||||
Popover,
|
|
||||||
ScrollSpy,
|
|
||||||
Offcanvas
|
|
||||||
} from 'bootstrap'
|
|
||||||
170
core/libs.json
170
core/libs.json
@@ -1,170 +0,0 @@
|
|||||||
{
|
|
||||||
"imask": {
|
|
||||||
"npm": "imask",
|
|
||||||
"js": [
|
|
||||||
"dist/imask.min.js"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"autosize": {
|
|
||||||
"npm": "autosize",
|
|
||||||
"js": [
|
|
||||||
"dist/autosize.min.js"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"apexcharts": {
|
|
||||||
"npm": "apexcharts",
|
|
||||||
"js": [
|
|
||||||
"dist/apexcharts.min.js"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"nouislider": {
|
|
||||||
"npm": "nouislider",
|
|
||||||
"js": [
|
|
||||||
"dist/nouislider.min.js"
|
|
||||||
],
|
|
||||||
"css": [
|
|
||||||
"dist/nouislider.min.css"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"countup": {
|
|
||||||
"npm": "countup.js",
|
|
||||||
"js": [
|
|
||||||
"dist/countUp.umd.js"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"lists": {
|
|
||||||
"npm": "list.js",
|
|
||||||
"js": [
|
|
||||||
"dist/list.min.js"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"sortablejs": {
|
|
||||||
"npm": "sortablejs",
|
|
||||||
"js": [
|
|
||||||
"Sortable.min.js"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"masonry": {
|
|
||||||
"js": [
|
|
||||||
"https://cdnjs.cloudflare.com/ajax/libs/masonry/4.2.2/masonry.pkgd.min.js"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"mapbox": {
|
|
||||||
"js": [
|
|
||||||
"https://api.mapbox.com/mapbox-gl-js/v1.8.0/mapbox-gl.js"
|
|
||||||
],
|
|
||||||
"css": [
|
|
||||||
"https://api.mapbox.com/mapbox-gl-js/v1.8.0/mapbox-gl.css"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"google-maps": {
|
|
||||||
"js": [
|
|
||||||
"https://maps.googleapis.com/maps/api/js?key=GOOGLE_MAPS_KEY"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"litepicker": {
|
|
||||||
"npm": "litepicker",
|
|
||||||
"js": [
|
|
||||||
"dist/litepicker.js"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"tom-select": {
|
|
||||||
"npm": "tom-select",
|
|
||||||
"js": [
|
|
||||||
"dist/js/tom-select.base.min.js"
|
|
||||||
],
|
|
||||||
"css": [
|
|
||||||
"dist/css/tom-select.bootstrap5.min.css"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"jsvectormap": {
|
|
||||||
"npm": "jsvectormap",
|
|
||||||
"js": [
|
|
||||||
"dist/jsvectormap.min.js",
|
|
||||||
"dist/maps/world.js",
|
|
||||||
"dist/maps/world-merc.js"
|
|
||||||
],
|
|
||||||
"css": [
|
|
||||||
"dist/jsvectormap.css"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"fslightbox": {
|
|
||||||
"npm": "fslightbox",
|
|
||||||
"js": [
|
|
||||||
"index.js"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"hugerte": {
|
|
||||||
"npm": "hugerte",
|
|
||||||
"js": [
|
|
||||||
"hugerte.min.js"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"plyr": {
|
|
||||||
"npm": "plyr",
|
|
||||||
"js": [
|
|
||||||
"dist/plyr.min.js"
|
|
||||||
],
|
|
||||||
"css": [
|
|
||||||
"dist/plyr.css"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"dropzone": {
|
|
||||||
"npm": "dropzone",
|
|
||||||
"js": [
|
|
||||||
"dist/dropzone-min.js"
|
|
||||||
],
|
|
||||||
"css": [
|
|
||||||
"dist/dropzone.css"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"star-rating.js": {
|
|
||||||
"npm": "star-rating.js",
|
|
||||||
"js": [
|
|
||||||
"dist/star-rating.min.js"
|
|
||||||
],
|
|
||||||
"css": [
|
|
||||||
"dist/star-rating.min.css"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"coloris.js": {
|
|
||||||
"npm": "@melloware/coloris",
|
|
||||||
"js": [
|
|
||||||
"dist/umd/coloris.min.js"
|
|
||||||
],
|
|
||||||
"css": [
|
|
||||||
"dist/coloris.min.css"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"typed.js": {
|
|
||||||
"npm": "typed.js",
|
|
||||||
"js": [
|
|
||||||
"dist/typed.umd.js"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"signature_pad": {
|
|
||||||
"npm": "signature_pad",
|
|
||||||
"js": [
|
|
||||||
"dist/signature_pad.umd.min.js"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"clipboard": {
|
|
||||||
"npm": "clipboard",
|
|
||||||
"js": [
|
|
||||||
"dist/clipboard.min.js"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"fullcalendar": {
|
|
||||||
"npm": "fullcalendar",
|
|
||||||
"js": [
|
|
||||||
"index.global.min.js"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"turbo": {
|
|
||||||
"npm": "@hotwired/turbo",
|
|
||||||
"js": [
|
|
||||||
"dist/turbo.es2017-umd.js"
|
|
||||||
],
|
|
||||||
"head": true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,179 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "@tabler/core",
|
|
||||||
"version": "1.4.0",
|
|
||||||
"description": "Premium and Open Source dashboard template with responsive and high quality UI.",
|
|
||||||
"homepage": "https://tabler.io",
|
|
||||||
"scripts": {
|
|
||||||
"dev": "pnpm run clean && pnpm run copy && pnpm run watch",
|
|
||||||
"build": "pnpm run clean && pnpm run css && pnpm run js && pnpm run copy && pnpm run generate-sri",
|
|
||||||
"clean": "shx rm -rf dist demo",
|
|
||||||
"css": "pnpm run css-compile && pnpm run css-prefix && pnpm run css-rtl && pnpm run css-minify && pnpm run css-banner",
|
|
||||||
"css-compile": "sass --no-source-map --load-path=node_modules --style expanded scss/:dist/css/",
|
|
||||||
"css-banner": "node .build/add-banner.mjs",
|
|
||||||
"css-prefix": "postcss --config .build/postcss.config.mjs --replace \"dist/css/*.css\" \"!dist/css/*.rtl*.css\" \"!dist/css/*.min.css\"",
|
|
||||||
"css-rtl": "cross-env NODE_ENV=RTL postcss --config .build/postcss.config.mjs --dir \"dist/css\" --ext \".rtl.css\" \"dist/css/*.css\" \"!dist/css/*.min.css\" \"!dist/css/*.rtl.css\"",
|
|
||||||
"css-minify": "pnpm run css-minify-main && pnpm run css-minify-rtl",
|
|
||||||
"css-minify-main": "cleancss -O1 --format breakWith=lf --with-rebase --source-map --source-map-inline-sources --output dist/css/ --batch --batch-suffix \".min\" \"dist/css/*.css\" \"!dist/css/*.min.css\" \"!dist/css/*rtl*.css\"",
|
|
||||||
"css-minify-rtl": "cleancss -O1 --format breakWith=lf --with-rebase --source-map --source-map-inline-sources --output dist/css/ --batch --batch-suffix \".min\" \"dist/css/*rtl.css\" \"!dist/css/*.min.css\"",
|
|
||||||
"js": "pnpm run js-compile && pnpm run js-minify",
|
|
||||||
"js-compile": "pnpm run js-compile-standalone && pnpm run js-compile-standalone-esm && pnpm run js-compile-theme && pnpm run js-compile-theme-esm",
|
|
||||||
"js-compile-theme-esm": "rollup --environment THEME:true --environment ESM:true --config .build/rollup.config.mjs --sourcemap",
|
|
||||||
"js-compile-theme": "rollup --environment THEME:true --config .build/rollup.config.mjs --sourcemap",
|
|
||||||
"js-compile-standalone": "rollup --config .build/rollup.config.mjs --sourcemap",
|
|
||||||
"js-compile-standalone-esm": "rollup --environment ESM:true --config .build/rollup.config.mjs --sourcemap",
|
|
||||||
"js-minify": "pnpm run js-minify-standalone && pnpm run js-minify-standalone-esm && pnpm run js-minify-theme && pnpm run js-minify-theme-esm",
|
|
||||||
"js-minify-standalone": "terser --compress passes=2 --mangle --comments \"/^!/\" --source-map \"content=dist/js/tabler.js.map,includeSources,url=tabler.min.js.map\" --output dist/js/tabler.min.js dist/js/tabler.js",
|
|
||||||
"js-minify-standalone-esm": "terser --compress passes=2 --mangle --comments \"/^!/\" --source-map \"content=dist/js/tabler.esm.js.map,includeSources,url=tabler.esm.min.js.map\" --output dist/js/tabler.esm.min.js dist/js/tabler.esm.js",
|
|
||||||
"js-minify-theme": "terser --compress passes=2 --mangle --comments \"/^!/\" --source-map \"content=dist/js/tabler-theme.js.map,includeSources,url=tabler-theme.min.js.map\" --output dist/js/tabler-theme.min.js dist/js/tabler-theme.js",
|
|
||||||
"js-minify-theme-esm": "terser --compress passes=2 --mangle --comments \"/^!/\" --source-map \"content=dist/js/tabler-theme.esm.js.map,includeSources,url=tabler-theme.esm.min.js.map\" --output dist/js/tabler-theme.esm.min.js dist/js/tabler-theme.esm.js",
|
|
||||||
"copy": "pnpm run copy-img && pnpm run copy-libs",
|
|
||||||
"copy-img": "shx mkdir -p dist/img && shx cp -rf img/* dist/img",
|
|
||||||
"copy-libs": "node .build/copy-libs.mjs",
|
|
||||||
"watch": "concurrently \"pnpm run watch-css\" \"pnpm run watch-js\"",
|
|
||||||
"watch-css": "nodemon --watch scss/ --ext scss --exec \"pnpm run css-compile && pnpm run css-prefix\"",
|
|
||||||
"watch-js": "nodemon --watch js/ --ext js --exec \"pnpm run js-compile\"",
|
|
||||||
"bundlewatch": "bundlewatch",
|
|
||||||
"generate-sri": "node .build/generate-sri.js",
|
|
||||||
"format:check": "prettier --check src/**/*.{js,scss} --cache",
|
|
||||||
"format:write": "prettier --write src/**/*.{js,scss} --cache"
|
|
||||||
},
|
|
||||||
"repository": {
|
|
||||||
"type": "git",
|
|
||||||
"url": "git+https://github.com/tabler/tabler.git"
|
|
||||||
},
|
|
||||||
"keywords": [
|
|
||||||
"css",
|
|
||||||
"sass",
|
|
||||||
"mobile-first",
|
|
||||||
"responsive",
|
|
||||||
"front-end",
|
|
||||||
"framework",
|
|
||||||
"web"
|
|
||||||
],
|
|
||||||
"author": "codecalm",
|
|
||||||
"license": "MIT",
|
|
||||||
"bugs": {
|
|
||||||
"url": "https://github.com/tabler/tabler/issues"
|
|
||||||
},
|
|
||||||
"funding": {
|
|
||||||
"type": "github",
|
|
||||||
"url": "https://github.com/sponsors/codecalm"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=20"
|
|
||||||
},
|
|
||||||
"files": [
|
|
||||||
"docs/**/*",
|
|
||||||
"dist/**/*",
|
|
||||||
"js/**/*.{js,map}",
|
|
||||||
"img/**/*.{svg}",
|
|
||||||
"scss/**/*.scss",
|
|
||||||
"libs.json"
|
|
||||||
],
|
|
||||||
"style": "dist/css/tabler.css",
|
|
||||||
"sass": "scss/tabler.scss",
|
|
||||||
"unpkg": "dist/js/tabler.min.js",
|
|
||||||
"umd:main": "dist/js/tabler.min.js",
|
|
||||||
"module": "dist/js/tabler.esm.js",
|
|
||||||
"main": "dist/js/tabler.js",
|
|
||||||
"bundlewatch": {
|
|
||||||
"files": [
|
|
||||||
{
|
|
||||||
"path": "./dist/css/tabler.css",
|
|
||||||
"maxSize": "75 kB"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"path": "./dist/css/tabler.min.css",
|
|
||||||
"maxSize": "70 kB"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"path": "./dist/css/tabler.rtl.css",
|
|
||||||
"maxSize": "75 kB"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"path": "./dist/css/tabler.rtl.min.css",
|
|
||||||
"maxSize": "70 kB"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"path": "./dist/css/tabler-flags.css",
|
|
||||||
"maxSize": "2.5 kB"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"path": "./dist/css/tabler-flags.min.css",
|
|
||||||
"maxSize": "2 kB"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"path": "./dist/css/tabler-payments.css",
|
|
||||||
"maxSize": "2.2 kB"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"path": "./dist/css/tabler-payments.min.css",
|
|
||||||
"maxSize": "2 kB"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"path": "./dist/css/tabler-socials.css",
|
|
||||||
"maxSize": "2 kB"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"path": "./dist/css/tabler-socials.min.css",
|
|
||||||
"maxSize": "2 kB"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"path": "./dist/css/tabler-vendors.css",
|
|
||||||
"maxSize": "7.5 kB"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"path": "./dist/css/tabler-vendors.min.css",
|
|
||||||
"maxSize": "6.5 kB"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"path": "./dist/js/tabler.js",
|
|
||||||
"maxSize": "60 kB"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"path": "./dist/js/tabler.min.js",
|
|
||||||
"maxSize": "45 kB"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"path": "./dist/js/tabler.esm.js",
|
|
||||||
"maxSize": "60 kB"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"path": "./dist/js/tabler.esm.min.js",
|
|
||||||
"maxSize": "45 kB"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"dependencies": {
|
|
||||||
"@popperjs/core": "^2.11.8",
|
|
||||||
"bootstrap": "5.3.8"
|
|
||||||
},
|
|
||||||
"devDependencies": {
|
|
||||||
"@hotwired/turbo": "^8.0.13",
|
|
||||||
"@melloware/coloris": "^0.25.0",
|
|
||||||
"apexcharts": "3.54.1",
|
|
||||||
"autosize": "^6.0.1",
|
|
||||||
"choices.js": "^11.1.0",
|
|
||||||
"clipboard": "^2.0.11",
|
|
||||||
"countup.js": "^2.9.0",
|
|
||||||
"dropzone": "^6.0.0-beta.2",
|
|
||||||
"flatpickr": "^4.6.13",
|
|
||||||
"fslightbox": "^3.7.4",
|
|
||||||
"fullcalendar": "^6.1.19",
|
|
||||||
"hugerte": "^1.0.9",
|
|
||||||
"imask": "^7.6.1",
|
|
||||||
"jsvectormap": "^1.7.0",
|
|
||||||
"list.js": "^2.3.1",
|
|
||||||
"litepicker": "^2.0.12",
|
|
||||||
"nouislider": "^15.8.1",
|
|
||||||
"plyr": "^3.8.3",
|
|
||||||
"signature_pad": "^5.1.1",
|
|
||||||
"sortablejs": "^1.15.6",
|
|
||||||
"star-rating.js": "^4.3.1",
|
|
||||||
"tom-select": "^2.4.3",
|
|
||||||
"typed.js": "^2.1.0"
|
|
||||||
},
|
|
||||||
"directories": {
|
|
||||||
"doc": "docs"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,92 +0,0 @@
|
|||||||
@use "sass:map";
|
|
||||||
@import "config";
|
|
||||||
|
|
||||||
:root,
|
|
||||||
:host {
|
|
||||||
/** Fonts */
|
|
||||||
--#{$prefix}font-monospace: #{$font-family-monospace};
|
|
||||||
--#{$prefix}font-sans-serif: #{$font-family-sans-serif};
|
|
||||||
--#{$prefix}font-serif: #{$font-family-serif};
|
|
||||||
--#{$prefix}font-comic: #{$font-family-comic};
|
|
||||||
|
|
||||||
/** Gray colors */
|
|
||||||
--#{$prefix}gray-50: #{$gray-50};
|
|
||||||
--#{$prefix}gray-100: #{$gray-100};
|
|
||||||
--#{$prefix}gray-200: #{$gray-200};
|
|
||||||
--#{$prefix}gray-300: #{$gray-300};
|
|
||||||
--#{$prefix}gray-400: #{$gray-400};
|
|
||||||
--#{$prefix}gray-500: #{$gray-500};
|
|
||||||
--#{$prefix}gray-600: #{$gray-600};
|
|
||||||
--#{$prefix}gray-700: #{$gray-700};
|
|
||||||
--#{$prefix}gray-800: #{$gray-800};
|
|
||||||
--#{$prefix}gray-900: #{$gray-900};
|
|
||||||
--#{$prefix}gray-950: #{$gray-950};
|
|
||||||
|
|
||||||
--#{$prefix}white: #{$white};
|
|
||||||
--#{$prefix}black: #{$black};
|
|
||||||
--#{$prefix}dark: #{$dark};
|
|
||||||
--#{$prefix}light: #{$light};
|
|
||||||
|
|
||||||
/** Brand colors */
|
|
||||||
--#{$prefix}brand: #{$primary};
|
|
||||||
|
|
||||||
/** Theme colors */
|
|
||||||
@each $name, $color in map.merge($theme-colors, $social-colors) {
|
|
||||||
--#{$prefix}#{$name}: #{$color};
|
|
||||||
--#{$prefix}#{$name}-rgb: #{to-rgb($color)};
|
|
||||||
--#{$prefix}#{$name}-fg: #{if(contrast-ratio($color) > $min-contrast-ratio, var(--#{$prefix}light), var(--#{$prefix}dark))};
|
|
||||||
--#{$prefix}#{$name}-darken: #{theme-color-darker($color)};
|
|
||||||
--#{$prefix}#{$name}-darken: color-mix(in oklab, var(--#{$prefix}#{$name}), transparent 20%);
|
|
||||||
--#{$prefix}#{$name}-lt: #{theme-color-lighter($color)};
|
|
||||||
--#{$prefix}#{$name}-lt: color-mix(in oklab, var(--#{$prefix}#{$name}) 10%, transparent);
|
|
||||||
--#{$prefix}#{$name}-200: color-mix(in oklab, var(--#{$prefix}#{$name}) 20%, transparent);
|
|
||||||
--#{$prefix}#{$name}-lt-rgb: #{to-rgb(theme-color-lighter($color))};
|
|
||||||
}
|
|
||||||
|
|
||||||
/** Gray colors */
|
|
||||||
@each $name, $color in $gray-colors {
|
|
||||||
--#{$prefix}#{$name}-fg: #{if(contrast-ratio($color, white) > $min-contrast-ratio, var(--#{$prefix}white), var(--#{$prefix}body-color))};
|
|
||||||
}
|
|
||||||
|
|
||||||
/** Spacers */
|
|
||||||
@each $name, $value in $spacers {
|
|
||||||
--#{$prefix}spacer-#{$name}: #{$value};
|
|
||||||
}
|
|
||||||
|
|
||||||
/** Font sizes */
|
|
||||||
@each $name, $value in $font-weights {
|
|
||||||
--#{$prefix}font-weight-#{$name}: #{$value};
|
|
||||||
}
|
|
||||||
|
|
||||||
@each $name, $value in $font-sizes {
|
|
||||||
--#{$prefix}font-size-h#{$name}: #{$value};
|
|
||||||
}
|
|
||||||
|
|
||||||
@each $name, $value in $line-heights {
|
|
||||||
--#{$prefix}line-height-#{$name}: #{$value};
|
|
||||||
}
|
|
||||||
|
|
||||||
/** Shadows */
|
|
||||||
@each $name, $value in $box-shadows {
|
|
||||||
--#{$prefix}shadow#{if($name, '-#{$name}', '')}: #{$value};
|
|
||||||
}
|
|
||||||
|
|
||||||
/** Border radiuses */
|
|
||||||
--#{$prefix}border-radius-scale: 1;
|
|
||||||
@each $name, $value in $border-radiuses {
|
|
||||||
@if $name {
|
|
||||||
--#{$prefix}border-radius-#{$name}: calc(#{$value} * var(--#{$prefix}border-radius-scale, 1));
|
|
||||||
} @else {
|
|
||||||
--#{$prefix}border-radius: #{$value};
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/** Backdrops */
|
|
||||||
--#{$prefix}backdrop-opacity: #{$backdrop-opacity};
|
|
||||||
--#{$prefix}backdrop-bg: var(--#{$prefix}bg-surface-dark);
|
|
||||||
@each $name, $value in $backdrops {
|
|
||||||
--#{$prefix}backdrop-bg#{if($name, '-#{$name}', '')}: #{$value};
|
|
||||||
}
|
|
||||||
--#{$prefix}backdrop-blur: #{$backdrop-blur};
|
|
||||||
--#{$prefix}backdrop-filter: blur(var(--#{$prefix}backdrop-blur));
|
|
||||||
}
|
|
||||||
@@ -1,145 +0,0 @@
|
|||||||
@use "sass:map";
|
|
||||||
|
|
||||||
//
|
|
||||||
// Clearfix
|
|
||||||
//
|
|
||||||
.clearfix {
|
|
||||||
@include clearfix();
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
|
||||||
// Text truncation
|
|
||||||
//
|
|
||||||
.text-truncate {
|
|
||||||
@include text-truncate();
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
|
||||||
// Vertical rule
|
|
||||||
//
|
|
||||||
.vr {
|
|
||||||
display: inline-block;
|
|
||||||
align-self: stretch;
|
|
||||||
width: $vr-border-width;
|
|
||||||
min-height: 1em;
|
|
||||||
background-color: currentcolor;
|
|
||||||
opacity: $hr-opacity;
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
|
||||||
// Stretched link
|
|
||||||
//
|
|
||||||
.stretched-link {
|
|
||||||
&::#{$stretched-link-pseudo-element} {
|
|
||||||
position: absolute;
|
|
||||||
top: 0;
|
|
||||||
right: 0;
|
|
||||||
bottom: 0;
|
|
||||||
left: 0;
|
|
||||||
z-index: $stretched-link-z-index;
|
|
||||||
content: "";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
|
||||||
// Visually hidden
|
|
||||||
//
|
|
||||||
.visually-hidden,
|
|
||||||
.visually-hidden-focusable:not(:focus):not(:focus-within) {
|
|
||||||
@include visually-hidden();
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
|
||||||
// Stacks
|
|
||||||
//
|
|
||||||
.hstack {
|
|
||||||
display: flex;
|
|
||||||
flex-direction: row;
|
|
||||||
align-items: center;
|
|
||||||
align-self: stretch;
|
|
||||||
}
|
|
||||||
|
|
||||||
.vstack {
|
|
||||||
display: flex;
|
|
||||||
flex: 1 1 auto;
|
|
||||||
flex-direction: column;
|
|
||||||
align-self: stretch;
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
|
||||||
// Position
|
|
||||||
//
|
|
||||||
// Shorthand
|
|
||||||
|
|
||||||
.fixed-top {
|
|
||||||
position: fixed;
|
|
||||||
top: 0;
|
|
||||||
right: 0;
|
|
||||||
left: 0;
|
|
||||||
z-index: $zindex-fixed;
|
|
||||||
}
|
|
||||||
|
|
||||||
.fixed-bottom {
|
|
||||||
position: fixed;
|
|
||||||
right: 0;
|
|
||||||
bottom: 0;
|
|
||||||
left: 0;
|
|
||||||
z-index: $zindex-fixed;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Responsive sticky top and bottom
|
|
||||||
@each $breakpoint in map.keys($grid-breakpoints) {
|
|
||||||
@include media-breakpoint-up($breakpoint) {
|
|
||||||
$infix: breakpoint-infix($breakpoint, $grid-breakpoints);
|
|
||||||
|
|
||||||
.sticky#{$infix}-top {
|
|
||||||
position: sticky;
|
|
||||||
top: 0;
|
|
||||||
z-index: $zindex-sticky;
|
|
||||||
}
|
|
||||||
|
|
||||||
.sticky#{$infix}-bottom {
|
|
||||||
position: sticky;
|
|
||||||
bottom: 0;
|
|
||||||
z-index: $zindex-sticky;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
|
||||||
// Aspect ratio
|
|
||||||
//
|
|
||||||
.ratio {
|
|
||||||
position: relative;
|
|
||||||
width: 100%;
|
|
||||||
|
|
||||||
&::before {
|
|
||||||
display: block;
|
|
||||||
padding-top: var(--#{$prefix}aspect-ratio);
|
|
||||||
content: "";
|
|
||||||
}
|
|
||||||
|
|
||||||
> * {
|
|
||||||
position: absolute;
|
|
||||||
top: 0;
|
|
||||||
left: 0;
|
|
||||||
width: 100%;
|
|
||||||
height: 100%;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@each $key, $ratio in $aspect-ratios {
|
|
||||||
.ratio-#{$key} {
|
|
||||||
--#{$prefix}aspect-ratio: #{$ratio};
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
|
||||||
// Focus ring
|
|
||||||
//
|
|
||||||
.focus-ring:focus {
|
|
||||||
outline: 0;
|
|
||||||
// By default, there is no `--bs-focus-ring-x`, `--bs-focus-ring-y`, or `--bs-focus-ring-blur`, but we provide CSS variables with fallbacks to initial `0` values
|
|
||||||
box-shadow: var(--#{$prefix}focus-ring-x, 0) var(--#{$prefix}focus-ring-y, 0) var(--#{$prefix}focus-ring-blur, 0) var(--#{$prefix}focus-ring-width) var(--#{$prefix}focus-ring-color);
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -1,98 +0,0 @@
|
|||||||
@keyframes pulse {
|
|
||||||
0% {
|
|
||||||
transform: scale(1);
|
|
||||||
}
|
|
||||||
|
|
||||||
14% {
|
|
||||||
transform: scale(1.25);
|
|
||||||
}
|
|
||||||
|
|
||||||
28% {
|
|
||||||
transform: scale(1);
|
|
||||||
}
|
|
||||||
|
|
||||||
42% {
|
|
||||||
transform: scale(1.25);
|
|
||||||
}
|
|
||||||
|
|
||||||
70% {
|
|
||||||
transform: scale(1);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes tada {
|
|
||||||
0% {
|
|
||||||
transform: scale3d(1, 1, 1);
|
|
||||||
}
|
|
||||||
|
|
||||||
10%,
|
|
||||||
5% {
|
|
||||||
transform: scale3d(0.9, 0.9, 0.9) rotate3d(0, 0, 1, -5deg);
|
|
||||||
}
|
|
||||||
|
|
||||||
15%,
|
|
||||||
25%,
|
|
||||||
35%,
|
|
||||||
45% {
|
|
||||||
transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 5deg);
|
|
||||||
}
|
|
||||||
|
|
||||||
20%,
|
|
||||||
30%,
|
|
||||||
40% {
|
|
||||||
transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, -5deg);
|
|
||||||
}
|
|
||||||
|
|
||||||
50% {
|
|
||||||
transform: scale3d(1, 1, 1);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes rotate-360 {
|
|
||||||
from {
|
|
||||||
transform: rotate(0deg);
|
|
||||||
}
|
|
||||||
|
|
||||||
to {
|
|
||||||
transform: rotate(360deg);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes blink {
|
|
||||||
from {
|
|
||||||
opacity: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
50% {
|
|
||||||
opacity: 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
to {
|
|
||||||
opacity: 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes shake {
|
|
||||||
0% {
|
|
||||||
transform: scaleX(1);
|
|
||||||
}
|
|
||||||
|
|
||||||
20% {
|
|
||||||
transform: scale3d(0.9, 0.9, 0.9) rotate(-5deg);
|
|
||||||
}
|
|
||||||
|
|
||||||
50%,
|
|
||||||
70%,
|
|
||||||
90% {
|
|
||||||
transform: scale3d(1.25, 1.25, 1.25) rotate(5deg);
|
|
||||||
}
|
|
||||||
|
|
||||||
60%,
|
|
||||||
80% {
|
|
||||||
transform: scale3d(1.25, 1.25, 1.25) rotate(-5deg);
|
|
||||||
}
|
|
||||||
|
|
||||||
to {
|
|
||||||
transform: scaleX(1);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,22 +0,0 @@
|
|||||||
@use "sass:map";
|
|
||||||
|
|
||||||
// stylelint-disable property-no-vendor-prefix
|
|
||||||
body {
|
|
||||||
letter-spacing: $body-letter-spacing;
|
|
||||||
touch-action: manipulation;
|
|
||||||
text-rendering: optimizeLegibility;
|
|
||||||
font-feature-settings: "liga" 0, "cv03", "cv04", "cv11";
|
|
||||||
position: relative;
|
|
||||||
min-height: 100%;
|
|
||||||
height: 100%;
|
|
||||||
padding: 0;
|
|
||||||
|
|
||||||
-webkit-font-smoothing: antialiased;
|
|
||||||
-moz-osx-font-smoothing: grayscale;
|
|
||||||
|
|
||||||
@media print {
|
|
||||||
background: transparent;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@include scrollbar;
|
|
||||||
@@ -1,74 +0,0 @@
|
|||||||
@use "sass:color";
|
|
||||||
|
|
||||||
// stylelint-disable declaration-no-important
|
|
||||||
|
|
||||||
@if $enable-dark-mode {
|
|
||||||
:root {
|
|
||||||
&:not(.theme-dark):not([data-bs-theme="dark"]) {
|
|
||||||
.hide-theme-light {
|
|
||||||
display: none !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.img-dark {
|
|
||||||
display: none !important;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
&.theme-dark,
|
|
||||||
&[data-bs-theme="dark"] {
|
|
||||||
.hide-theme-dark {
|
|
||||||
display: none !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.img-light {
|
|
||||||
display: none !important;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
@include color-mode(dark, true) {
|
|
||||||
color-scheme: dark;
|
|
||||||
--#{$prefix}body-color: var(--#{$prefix}gray-200);
|
|
||||||
--#{$prefix}secondary: var(--#{$prefix}gray-400);
|
|
||||||
|
|
||||||
--#{$prefix}body-bg: var(--#{$prefix}gray-900);
|
|
||||||
--#{$prefix}emphasis-color: #{$body-emphasis-color-dark};
|
|
||||||
--#{$prefix}emphasis-color-rgb: #{to-rgb($body-emphasis-color-dark)};
|
|
||||||
|
|
||||||
--#{$prefix}bg-forms: var(--#{$prefix}gray-900);
|
|
||||||
--#{$prefix}bg-surface: var(--#{$prefix}gray-800);
|
|
||||||
--#{$prefix}bg-surface-inverted: var(--#{$prefix}gray-100);
|
|
||||||
--#{$prefix}bg-surface-secondary: var(--#{$prefix}gray-900);
|
|
||||||
--#{$prefix}bg-surface-tertiary: var(--#{$prefix}gray-800);
|
|
||||||
|
|
||||||
--#{$prefix}text-inverted: var(--#{$prefix}gray-800);
|
|
||||||
|
|
||||||
--#{$prefix}link-color: var(--#{$prefix}primary);
|
|
||||||
--#{$prefix}link-hover-color: color-mix(in srgb, var(--#{$prefix}primary), black 20%);
|
|
||||||
|
|
||||||
--#{$prefix}active-bg: #{$lighten-dark};
|
|
||||||
--#{$prefix}disabled-color: #{color-transparent(var(--#{$prefix}body-color), .4)};
|
|
||||||
|
|
||||||
--#{$prefix}border-color: var(--#{$prefix}gray-700);
|
|
||||||
--#{$prefix}border-color-translucent: var(
|
|
||||||
--#{$prefix}dark-mode-border-color-translucent
|
|
||||||
);
|
|
||||||
--#{$prefix}border-dark-color: var(--#{$prefix}dark-mode-border-dark-color);
|
|
||||||
--#{$prefix}border-active-color: var(
|
|
||||||
--#{$prefix}dark-mode-border-active-color
|
|
||||||
);
|
|
||||||
|
|
||||||
--#{$prefix}btn-color: #{$darken-dark};
|
|
||||||
|
|
||||||
.navbar-brand-autodark {
|
|
||||||
.navbar-brand-image {
|
|
||||||
@include autodark-image;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
body[data-bs-theme=dark] [data-bs-theme=light] {
|
|
||||||
@extend [data-bs-theme=dark];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
.body-marketing {
|
|
||||||
--#{$prefix}body-font-size: 1rem;
|
|
||||||
--#{$prefix}body-line-height: 1.75;
|
|
||||||
}
|
|
||||||
|
|
||||||
.body-gradient {
|
|
||||||
background: var(--#{$prefix}bg-surface) linear-gradient(to bottom, var(--#{$prefix}bg-surface-secondary) 12%, var(--#{$prefix}bg-surface) 99%) repeat-x top center/100% 100vh;
|
|
||||||
}
|
|
||||||
@@ -1,406 +0,0 @@
|
|||||||
@use "sass:math";
|
|
||||||
@use "sass:string";
|
|
||||||
@use "sass:list";
|
|
||||||
@use "sass:map";
|
|
||||||
@use "sass:color";
|
|
||||||
@use "sass:meta";
|
|
||||||
|
|
||||||
@function theme-color-lighter($color, $background: #fff) {
|
|
||||||
@return color.mix($color, $background, 10%);
|
|
||||||
}
|
|
||||||
|
|
||||||
@function theme-color-darker($color) {
|
|
||||||
@return shade-color($color, 10%);
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
|
||||||
// Replace all occurrences of a substring within a string.
|
|
||||||
//
|
|
||||||
@function str-replace($string, $search, $replace: "") {
|
|
||||||
$index: string.index($string, $search);
|
|
||||||
|
|
||||||
@if $index {
|
|
||||||
@return string.slice($string, 1, $index - 1) + $replace + str-replace(string.slice($string, $index + string.length($search)), $search, $replace);
|
|
||||||
}
|
|
||||||
|
|
||||||
@return $string;
|
|
||||||
}
|
|
||||||
|
|
||||||
@mixin media-breakpoint-down-than($name, $breakpoints: $grid-breakpoints) {
|
|
||||||
$prev: breakpoint-prev($name);
|
|
||||||
|
|
||||||
@if $prev == null {
|
|
||||||
@content;
|
|
||||||
} @else {
|
|
||||||
$max: breakpoint-max($prev, $breakpoints);
|
|
||||||
|
|
||||||
@if $max {
|
|
||||||
@media (max-width: $max) {
|
|
||||||
@content;
|
|
||||||
}
|
|
||||||
} @else {
|
|
||||||
@content;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@function breakpoint-prev($name, $breakpoints: $grid-breakpoints, $breakpoint-names: map.keys($breakpoints)) {
|
|
||||||
$n: index($breakpoint-names, $name);
|
|
||||||
@if not $n {
|
|
||||||
@error "breakpoint `#{$name}` not found in `#{$breakpoints}`";
|
|
||||||
}
|
|
||||||
@return if($n > 1, list.nth($breakpoint-names, $n - 1), null);
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
|
||||||
// Escape SVG strings.
|
|
||||||
//
|
|
||||||
@function escape-svg($string) {
|
|
||||||
@if string.index($string, "data:image/svg+xml") {
|
|
||||||
@each $char, $encoded in $escaped-characters {
|
|
||||||
// Do not escape the url brackets
|
|
||||||
@if string.index($string, "url(") == 1 {
|
|
||||||
$string: url("#{str-replace(string.slice($string, 6, -3), $char, $encoded)}");
|
|
||||||
} @else {
|
|
||||||
$string: str-replace($string, $char, $encoded);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@return $string;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Converts a given value to a percentage string.
|
|
||||||
*
|
|
||||||
* @param {Number} $value - The value to be converted to a percentage.
|
|
||||||
* @return {String} - The percentage representation of the value.
|
|
||||||
*/
|
|
||||||
@function to-percentage($value) {
|
|
||||||
@return if(math.is-unitless($value), math.percentage($value), $value);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Generates a transparent version of the given color.
|
|
||||||
*
|
|
||||||
* @param {Color} $color - The base color to be made transparent.
|
|
||||||
* @param {Number} $alpha - The level of transparency, ranging from 0 (fully transparent) to 1 (fully opaque). Default is 1.
|
|
||||||
* @return {Color} - The resulting color with the specified transparency.
|
|
||||||
*/
|
|
||||||
@function color-transparent($color, $alpha: 1, $background: transparent) {
|
|
||||||
@if $alpha == 1 {
|
|
||||||
@return $color;
|
|
||||||
} @else {
|
|
||||||
@return color-mix(in srgb, #{$color} #{to-percentage($alpha)}, $background);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@function url-svg($svg) {
|
|
||||||
$svg: str-replace($svg, '#', '%23');
|
|
||||||
$svg: str-replace($svg, '<svg', '<svg xmlns="http://www.w3.org/2000/svg"');
|
|
||||||
|
|
||||||
@return url('data:image/svg+xml;charset=UTF-8,#{$svg}');
|
|
||||||
}
|
|
||||||
|
|
||||||
// Bootstrap functions
|
|
||||||
//
|
|
||||||
// Utility mixins and functions for evaluating source code across our variables, maps, and mixins.
|
|
||||||
|
|
||||||
// Ascending
|
|
||||||
// Used to evaluate Sass maps like our grid breakpoints.
|
|
||||||
@mixin _assert-ascending($map, $map-name) {
|
|
||||||
$prev-key: null;
|
|
||||||
$prev-num: null;
|
|
||||||
@each $key, $num in $map {
|
|
||||||
@if $prev-num == null or math.unit($num) == "%" or math.unit($prev-num) == "%" {
|
|
||||||
// Do nothing
|
|
||||||
} @else if not math.compatible($prev-num, $num) {
|
|
||||||
@warn "Potentially invalid value for #{$map-name}: This map must be in ascending order, but key '#{$key}' has value #{$num} whose unit makes it incomparable to #{$prev-num}, the value of the previous key '#{$prev-key}' !";
|
|
||||||
} @else if $prev-num >= $num {
|
|
||||||
@warn "Invalid value for #{$map-name}: This map must be in ascending order, but key '#{$key}' has value #{$num} which isn't greater than #{$prev-num}, the value of the previous key '#{$prev-key}' !";
|
|
||||||
}
|
|
||||||
$prev-key: $key;
|
|
||||||
$prev-num: $num;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Starts at zero
|
|
||||||
// Used to ensure the min-width of the lowest breakpoint starts at 0.
|
|
||||||
@mixin _assert-starts-at-zero($map, $map-name: "$grid-breakpoints") {
|
|
||||||
@if list.length($map) > 0 {
|
|
||||||
$values: map.values($map);
|
|
||||||
$first-value: list.nth($values, 1);
|
|
||||||
@if $first-value != 0 {
|
|
||||||
@warn "First breakpoint in #{$map-name} must start at 0, but starts at #{$first-value}.";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Colors
|
|
||||||
@function to-rgb($value) {
|
|
||||||
@return color.channel($value, "red", $space: rgb), color.channel($value, "green", $space: rgb), color.channel($value, "blue", $space: rgb);
|
|
||||||
}
|
|
||||||
|
|
||||||
// stylelint-disable scss/dollar-variable-pattern
|
|
||||||
@function rgba-css-var($identifier, $target) {
|
|
||||||
@if $identifier == "body" and $target == "bg" {
|
|
||||||
@return rgba(var(--#{$prefix}#{$identifier}-bg-rgb), var(--#{$prefix}#{$target}-opacity));
|
|
||||||
} @if $identifier == "body" and $target == "text" {
|
|
||||||
@return rgba(var(--#{$prefix}#{$identifier}-color-rgb), var(--#{$prefix}#{$target}-opacity));
|
|
||||||
} @else {
|
|
||||||
@return rgba(var(--#{$prefix}#{$identifier}-rgb), var(--#{$prefix}#{$target}-opacity));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@function map-loop($map, $func, $args...) {
|
|
||||||
$_map: ();
|
|
||||||
|
|
||||||
@each $key, $value in $map {
|
|
||||||
// allow to pass the $key and $value of the map as an function argument
|
|
||||||
$_args: ();
|
|
||||||
@each $arg in $args {
|
|
||||||
$_args: list.append($_args, if($arg == "$key", $key, if($arg == "$value", $value, $arg)));
|
|
||||||
}
|
|
||||||
|
|
||||||
$_map: map.merge($_map, ($key: meta.call(meta.get-function($func), $_args...)));
|
|
||||||
}
|
|
||||||
|
|
||||||
@return $_map;
|
|
||||||
}
|
|
||||||
// stylelint-enable scss/dollar-variable-pattern
|
|
||||||
|
|
||||||
@function varify($list) {
|
|
||||||
$result: null;
|
|
||||||
@each $entry in $list {
|
|
||||||
$result: list.append($result, var(--#{$prefix}#{$entry}), space);
|
|
||||||
}
|
|
||||||
@return $result;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Internal Bootstrap function to turn maps into its negative variant.
|
|
||||||
// It prefixes the keys with `n` and makes the value negative.
|
|
||||||
@function negativify-map($map) {
|
|
||||||
$result: ();
|
|
||||||
@each $key, $value in $map {
|
|
||||||
@if $key != 0 {
|
|
||||||
$result: map.merge($result, ("n" + $key: (-$value)));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@return $result;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Get multiple keys from a sass map
|
|
||||||
@function map-get-multiple($map, $values) {
|
|
||||||
$result: ();
|
|
||||||
@each $key, $value in $map {
|
|
||||||
@if (index($values, $key) != null) {
|
|
||||||
$result: map.merge($result, ($key: $value));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@return $result;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Merge multiple maps
|
|
||||||
@function map-merge-multiple($maps...) {
|
|
||||||
$merged-maps: ();
|
|
||||||
|
|
||||||
@each $map in $maps {
|
|
||||||
$merged-maps: map.merge($merged-maps, $map);
|
|
||||||
}
|
|
||||||
@return $merged-maps;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Replace `$search` with `$replace` in `$string`
|
|
||||||
// Used on our SVG icon backgrounds for custom forms.
|
|
||||||
//
|
|
||||||
// @author Kitty Giraudel
|
|
||||||
// @param {String} $string - Initial string
|
|
||||||
// @param {String} $search - Substring to replace
|
|
||||||
// @param {String} $replace ('') - New value
|
|
||||||
// @return {String} - Updated string
|
|
||||||
@function str-replace($string, $search, $replace: "") {
|
|
||||||
$index: string.index($string, $search);
|
|
||||||
|
|
||||||
@if $index {
|
|
||||||
@return string.slice($string, 1, $index - 1) + $replace + str-replace(string.slice($string, $index + string.length($search)), $search, $replace);
|
|
||||||
}
|
|
||||||
|
|
||||||
@return $string;
|
|
||||||
}
|
|
||||||
|
|
||||||
// See https://codepen.io/kevinweber/pen/dXWoRw
|
|
||||||
//
|
|
||||||
// Requires the use of quotes around data URIs.
|
|
||||||
|
|
||||||
@function escape-svg($string) {
|
|
||||||
@if string.index($string, "data:image/svg+xml") {
|
|
||||||
@each $char, $encoded in $escaped-characters {
|
|
||||||
// Do not escape the url brackets
|
|
||||||
@if string.index($string, "url(") == 1 {
|
|
||||||
$string: url("#{str-replace(string.slice($string, 6, -3), $char, $encoded)}");
|
|
||||||
} @else {
|
|
||||||
$string: str-replace($string, $char, $encoded);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@return $string;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Color contrast
|
|
||||||
// See https://github.com/twbs/bootstrap/pull/30168
|
|
||||||
|
|
||||||
// A list of pre-calculated numbers of pow(divide((divide($value, 255) + .055), 1.055), 2.4). (from 0 to 255)
|
|
||||||
// stylelint-disable-next-line scss/dollar-variable-default, scss/dollar-variable-pattern
|
|
||||||
$_luminance-list: .0008 .001 .0011 .0013 .0015 .0017 .002 .0022 .0025 .0027 .003 .0033 .0037 .004 .0044 .0048 .0052 .0056 .006 .0065 .007 .0075 .008 .0086 .0091 .0097 .0103 .011 .0116 .0123 .013 .0137 .0144 .0152 .016 .0168 .0176 .0185 .0194 .0203 .0212 .0222 .0232 .0242 .0252 .0262 .0273 .0284 .0296 .0307 .0319 .0331 .0343 .0356 .0369 .0382 .0395 .0409 .0423 .0437 .0452 .0467 .0482 .0497 .0513 .0529 .0545 .0561 .0578 .0595 .0612 .063 .0648 .0666 .0685 .0704 .0723 .0742 .0762 .0782 .0802 .0823 .0844 .0865 .0887 .0908 .0931 .0953 .0976 .0999 .1022 .1046 .107 .1095 .1119 .1144 .117 .1195 .1221 .1248 .1274 .1301 .1329 .1356 .1384 .1413 .1441 .147 .15 .1529 .1559 .159 .162 .1651 .1683 .1714 .1746 .1779 .1812 .1845 .1878 .1912 .1946 .1981 .2016 .2051 .2086 .2122 .2159 .2195 .2232 .227 .2307 .2346 .2384 .2423 .2462 .2502 .2542 .2582 .2623 .2664 .2705 .2747 .2789 .2831 .2874 .2918 .2961 .3005 .305 .3095 .314 .3185 .3231 .3278 .3325 .3372 .3419 .3467 .3515 .3564 .3613 .3663 .3712 .3763 .3813 .3864 .3916 .3968 .402 .4072 .4125 .4179 .4233 .4287 .4342 .4397 .4452 .4508 .4564 .4621 .4678 .4735 .4793 .4851 .491 .4969 .5029 .5089 .5149 .521 .5271 .5333 .5395 .5457 .552 .5583 .5647 .5711 .5776 .5841 .5906 .5972 .6038 .6105 .6172 .624 .6308 .6376 .6445 .6514 .6584 .6654 .6724 .6795 .6867 .6939 .7011 .7084 .7157 .7231 .7305 .7379 .7454 .7529 .7605 .7682 .7758 .7835 .7913 .7991 .807 .8148 .8228 .8308 .8388 .8469 .855 .8632 .8714 .8796 .8879 .8963 .9047 .9131 .9216 .9301 .9387 .9473 .956 .9647 .9734 .9823 .9911 1;
|
|
||||||
|
|
||||||
@function color-contrast($background, $color-contrast-dark: $color-contrast-dark, $color-contrast-light: $color-contrast-light, $min-contrast-ratio: $min-contrast-ratio) {
|
|
||||||
$foregrounds: $color-contrast-light, $color-contrast-dark, $white, $black;
|
|
||||||
$max-ratio: 0;
|
|
||||||
$max-ratio-color: null;
|
|
||||||
|
|
||||||
@each $color in $foregrounds {
|
|
||||||
$contrast-ratio: contrast-ratio($background, $color);
|
|
||||||
@if $contrast-ratio >= $min-contrast-ratio {
|
|
||||||
@return $color;
|
|
||||||
} @else if $contrast-ratio > $max-ratio {
|
|
||||||
$max-ratio: $contrast-ratio;
|
|
||||||
$max-ratio-color: $color;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@warn "Found no color leading to #{$min-contrast-ratio}:1 contrast ratio against #{$background}...";
|
|
||||||
|
|
||||||
@return $max-ratio-color;
|
|
||||||
}
|
|
||||||
|
|
||||||
@function contrast-ratio($background, $foreground: $color-contrast-light) {
|
|
||||||
$l1: luminance($background);
|
|
||||||
$l2: luminance(opaque($background, $foreground));
|
|
||||||
|
|
||||||
@return if($l1 > $l2, divide($l1 + .05, $l2 + .05), divide($l2 + .05, $l1 + .05));
|
|
||||||
}
|
|
||||||
|
|
||||||
// Return WCAG2.2 relative luminance
|
|
||||||
// See https://www.w3.org/TR/WCAG/#dfn-relative-luminance
|
|
||||||
// See https://www.w3.org/TR/WCAG/#dfn-contrast-ratio
|
|
||||||
@function luminance($color) {
|
|
||||||
$rgb: (
|
|
||||||
"r": math.round(color.channel($color, "red", $space: rgb)),
|
|
||||||
"g": math.round(color.channel($color, "green", $space: rgb)),
|
|
||||||
"b": math.round(color.channel($color, "blue", $space: rgb))
|
|
||||||
);
|
|
||||||
|
|
||||||
@each $name, $value in $rgb {
|
|
||||||
$value: if(divide($value, 255) < .04045, divide(divide($value, 255), 12.92), list.nth($_luminance-list, $value + 1));
|
|
||||||
$rgb: map.merge($rgb, ($name: $value));
|
|
||||||
}
|
|
||||||
|
|
||||||
@return (map.get($rgb, "r") * .2126) + (map.get($rgb, "g") * .7152) + (map.get($rgb, "b") * .0722);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Return opaque color
|
|
||||||
// opaque(#fff, rgba(0, 0, 0, .5)) => #808080
|
|
||||||
@function opaque($background, $foreground) {
|
|
||||||
@return color.mix(rgba($foreground, 1), $background, color.opacity($foreground) * 100%);
|
|
||||||
}
|
|
||||||
|
|
||||||
// scss-docs-start color-functions
|
|
||||||
// Tint a color: mix a color with white
|
|
||||||
@function tint-color($color, $weight) {
|
|
||||||
@return color.mix(white, $color, $weight);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Shade a color: mix a color with black
|
|
||||||
@function shade-color($color, $weight) {
|
|
||||||
@return color.mix(black, $color, $weight);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Shade the color if the weight is positive, else tint it
|
|
||||||
@function shift-color($color, $weight) {
|
|
||||||
@return if($weight > 0, shade-color($color, $weight), tint-color($color, -$weight));
|
|
||||||
}
|
|
||||||
// scss-docs-end color-functions
|
|
||||||
|
|
||||||
// Return valid calc
|
|
||||||
@function add($value1, $value2, $return-calc: true) {
|
|
||||||
@if $value1 == null {
|
|
||||||
@return $value2;
|
|
||||||
}
|
|
||||||
|
|
||||||
@if $value2 == null {
|
|
||||||
@return $value1;
|
|
||||||
}
|
|
||||||
|
|
||||||
@if meta.type-of($value1) == number and meta.type-of($value2) == number and math.compatible($value1, $value2) {
|
|
||||||
@return $value1 + $value2;
|
|
||||||
}
|
|
||||||
|
|
||||||
@return if($return-calc == true, calc(#{$value1} + #{$value2}), $value1 + string.unquote(" + ") + $value2);
|
|
||||||
}
|
|
||||||
|
|
||||||
@function subtract($value1, $value2, $return-calc: true) {
|
|
||||||
@if $value1 == null and $value2 == null {
|
|
||||||
@return null;
|
|
||||||
}
|
|
||||||
|
|
||||||
@if $value1 == null {
|
|
||||||
@return -$value2;
|
|
||||||
}
|
|
||||||
|
|
||||||
@if $value2 == null {
|
|
||||||
@return $value1;
|
|
||||||
}
|
|
||||||
|
|
||||||
@if meta.type-of($value1) == number and meta.type-of($value2) == number and math.compatible($value1, $value2) {
|
|
||||||
@return $value1 - $value2;
|
|
||||||
}
|
|
||||||
|
|
||||||
@if meta.type-of($value2) != number {
|
|
||||||
$value2: string.unquote("(") + $value2 + string.unquote(")");
|
|
||||||
}
|
|
||||||
|
|
||||||
@return if($return-calc == true, calc(#{$value1} - #{$value2}), $value1 + string.unquote(" - ") + $value2);
|
|
||||||
}
|
|
||||||
|
|
||||||
@function divide($dividend, $divisor, $precision: 10) {
|
|
||||||
$sign: if($dividend > 0 and $divisor > 0 or $dividend < 0 and $divisor < 0, 1, -1);
|
|
||||||
$dividend: math.abs($dividend);
|
|
||||||
$divisor: math.abs($divisor);
|
|
||||||
@if $dividend == 0 {
|
|
||||||
@return 0;
|
|
||||||
}
|
|
||||||
@if $divisor == 0 {
|
|
||||||
@error "Cannot divide by 0";
|
|
||||||
}
|
|
||||||
$remainder: $dividend;
|
|
||||||
$result: 0;
|
|
||||||
$factor: 10;
|
|
||||||
@while ($remainder > 0 and $precision >= 0) {
|
|
||||||
$quotient: 0;
|
|
||||||
@while ($remainder >= $divisor) {
|
|
||||||
$remainder: $remainder - $divisor;
|
|
||||||
$quotient: $quotient + 1;
|
|
||||||
}
|
|
||||||
$result: $result * 10 + $quotient;
|
|
||||||
$factor: $factor * .1;
|
|
||||||
$remainder: $remainder * 10;
|
|
||||||
$precision: $precision - 1;
|
|
||||||
@if ($precision < 0 and $remainder >= $divisor * 5) {
|
|
||||||
$result: $result + 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
$result: $result * $factor * $sign;
|
|
||||||
$dividend-unit: math.unit($dividend);
|
|
||||||
$divisor-unit: math.unit($divisor);
|
|
||||||
$unit-map: (
|
|
||||||
"px": 1px,
|
|
||||||
"rem": 1rem,
|
|
||||||
"em": 1em,
|
|
||||||
"%": 1%
|
|
||||||
);
|
|
||||||
@if ($dividend-unit != $divisor-unit and map.has-key($unit-map, $dividend-unit)) {
|
|
||||||
$result: $result * map.get($unit-map, $dividend-unit);
|
|
||||||
}
|
|
||||||
@return $result;
|
|
||||||
}
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
@import "props"
|
|
||||||
@@ -1,168 +0,0 @@
|
|||||||
@use "sass:map";
|
|
||||||
@import "config";
|
|
||||||
|
|
||||||
[data-bs-theme-base="slate"] {
|
|
||||||
--#{$prefix}gray-50: #f8fafc;
|
|
||||||
--#{$prefix}gray-100: #f1f5f9;
|
|
||||||
--#{$prefix}gray-200: #e2e8f0;
|
|
||||||
--#{$prefix}gray-300: #cbd5e1;
|
|
||||||
--#{$prefix}gray-400: #94a3b8;
|
|
||||||
--#{$prefix}gray-500: #64748b;
|
|
||||||
--#{$prefix}gray-600: #475569;
|
|
||||||
--#{$prefix}gray-700: #334155;
|
|
||||||
--#{$prefix}gray-800: #1e293b;
|
|
||||||
--#{$prefix}gray-900: #0f172a;
|
|
||||||
--#{$prefix}gray-950: #020617;
|
|
||||||
}
|
|
||||||
|
|
||||||
[data-bs-theme-base="gray"] {
|
|
||||||
--#{$prefix}gray-50: #f9fafb;
|
|
||||||
--#{$prefix}gray-100: #f3f4f6;
|
|
||||||
--#{$prefix}gray-200: #e5e7eb;
|
|
||||||
--#{$prefix}gray-300: #d1d5db;
|
|
||||||
--#{$prefix}gray-400: #9ca3af;
|
|
||||||
--#{$prefix}gray-500: #6b7280;
|
|
||||||
--#{$prefix}gray-600: #4b5563;
|
|
||||||
--#{$prefix}gray-700: #374151;
|
|
||||||
--#{$prefix}gray-800: #1f2937;
|
|
||||||
--#{$prefix}gray-900: #111827;
|
|
||||||
--#{$prefix}gray-950: #030712;
|
|
||||||
}
|
|
||||||
|
|
||||||
[data-bs-theme-base="zinc"] {
|
|
||||||
--#{$prefix}gray-50: #fafafa;
|
|
||||||
--#{$prefix}gray-100: #f4f4f5;
|
|
||||||
--#{$prefix}gray-200: #e4e4e7;
|
|
||||||
--#{$prefix}gray-300: #d4d4d8;
|
|
||||||
--#{$prefix}gray-400: #a1a1aa;
|
|
||||||
--#{$prefix}gray-500: #71717a;
|
|
||||||
--#{$prefix}gray-600: #52525b;
|
|
||||||
--#{$prefix}gray-700: #3f3f46;
|
|
||||||
--#{$prefix}gray-800: #27272a;
|
|
||||||
--#{$prefix}gray-900: #18181b;
|
|
||||||
--#{$prefix}gray-950: #09090b;
|
|
||||||
}
|
|
||||||
|
|
||||||
[data-bs-theme-base="neutral"] {
|
|
||||||
--#{$prefix}gray-50: #fafafa;
|
|
||||||
--#{$prefix}gray-100: #f5f5f5;
|
|
||||||
--#{$prefix}gray-200: #e5e5e5;
|
|
||||||
--#{$prefix}gray-300: #d4d4d4;
|
|
||||||
--#{$prefix}gray-400: #a3a3a3;
|
|
||||||
--#{$prefix}gray-500: #737373;
|
|
||||||
--#{$prefix}gray-600: #525252;
|
|
||||||
--#{$prefix}gray-700: #404040;
|
|
||||||
--#{$prefix}gray-800: #262626;
|
|
||||||
--#{$prefix}gray-900: #171717;
|
|
||||||
--#{$prefix}gray-950: #0a0a0a;
|
|
||||||
}
|
|
||||||
|
|
||||||
[data-bs-theme-base="stone"] {
|
|
||||||
--#{$prefix}gray-50: #fafaf9;
|
|
||||||
--#{$prefix}gray-100: #f5f5f4;
|
|
||||||
--#{$prefix}gray-200: #e7e5e4;
|
|
||||||
--#{$prefix}gray-300: #d6d3d1;
|
|
||||||
--#{$prefix}gray-400: #a8a29e;
|
|
||||||
--#{$prefix}gray-500: #78716c;
|
|
||||||
--#{$prefix}gray-600: #57534e;
|
|
||||||
--#{$prefix}gray-700: #44403c;
|
|
||||||
--#{$prefix}gray-800: #292524;
|
|
||||||
--#{$prefix}gray-900: #1c1917;
|
|
||||||
--#{$prefix}gray-950: #0c0a09;
|
|
||||||
}
|
|
||||||
|
|
||||||
[data-bs-theme-base="pink"] {
|
|
||||||
--#{$prefix}gray-50: #fdf2f8;
|
|
||||||
--#{$prefix}gray-100: #fce7f3;
|
|
||||||
--#{$prefix}gray-200: #fbcfe8;
|
|
||||||
--#{$prefix}gray-300: #f9a8d4;
|
|
||||||
--#{$prefix}gray-400: #f472b6;
|
|
||||||
--#{$prefix}gray-500: #ec4899;
|
|
||||||
--#{$prefix}gray-600: #db2777;
|
|
||||||
--#{$prefix}gray-700: #be185d;
|
|
||||||
--#{$prefix}gray-800: #9d174d;
|
|
||||||
--#{$prefix}gray-900: #831843;
|
|
||||||
--#{$prefix}gray-950: #500724;
|
|
||||||
}
|
|
||||||
|
|
||||||
@each $name, $value in $extra-colors {
|
|
||||||
[data-bs-theme-primary="#{$name}"] {
|
|
||||||
--#{$prefix}primary: #{$value};
|
|
||||||
--#{$prefix}primary-rgb: #{to-rgb($value)};
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@each $value in (0, .5, 1, 1.5, 2) {
|
|
||||||
[data-bs-theme-radius="#{$value}"] {
|
|
||||||
--#{$prefix}border-radius-scale: #{$value};
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
[data-bs-theme-primary="inverted"] {
|
|
||||||
--#{$prefix}primary: var(--#{$prefix}gray-800);
|
|
||||||
--#{$prefix}primary-fg: var(--#{$prefix}light);
|
|
||||||
--#{$prefix}primary-rgb: #{to-rgb($dark)};
|
|
||||||
|
|
||||||
&[data-bs-theme="dark"],
|
|
||||||
[data-bs-theme="dark"] {
|
|
||||||
--#{$prefix}primary: #{$light};
|
|
||||||
--#{$prefix}primary-fg: var(--#{$prefix}dark);
|
|
||||||
--#{$prefix}primary-rgb: #{to-rgb($light)};
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@each $name, $value in (monospace: $font-family-monospace, sans-serif: $font-family-sans-serif, serif: $font-family-serif, comic: $font-family-comic) {
|
|
||||||
[data-bs-theme-font="#{$name}"] {
|
|
||||||
--#{$prefix}body-font-family: var(--#{$prefix}font-#{$name});
|
|
||||||
|
|
||||||
@if $name == "monospace" {
|
|
||||||
--#{$prefix}body-font-size: 80%;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
|
||||||
// Fluid container
|
|
||||||
//
|
|
||||||
[data-bs-layout="fluid"] {
|
|
||||||
.container,
|
|
||||||
[class^="container-"],
|
|
||||||
[class*=" container-"] {
|
|
||||||
max-width: 100%;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
|
||||||
// Boxed container
|
|
||||||
//
|
|
||||||
[data-bs-layout="boxed"] {
|
|
||||||
--#{$prefix}theme-boxed-border-radius: 0;
|
|
||||||
--#{$prefix}theme-boxed-width: #{map.get($container-max-widths, xxl)};
|
|
||||||
|
|
||||||
@include media-breakpoint-up(md) {
|
|
||||||
background: $dark linear-gradient(to right, rgba(#fff, .1), transparent) fixed;
|
|
||||||
padding: 1rem;
|
|
||||||
--#{$prefix}theme-boxed-border-radius: #{$border-radius};
|
|
||||||
}
|
|
||||||
|
|
||||||
body {
|
|
||||||
background: transparent;
|
|
||||||
}
|
|
||||||
|
|
||||||
.page {
|
|
||||||
margin: 0 auto;
|
|
||||||
max-width: var(--#{$prefix}theme-boxed-width);
|
|
||||||
border-radius: var(--#{$prefix}theme-boxed-border-radius);
|
|
||||||
color: var(--#{$prefix}body-color);
|
|
||||||
|
|
||||||
@include media-breakpoint-up(md) {
|
|
||||||
border: var(--#{$prefix}border-width) var(--#{$prefix}border-style) var(--#{$prefix}border-color);
|
|
||||||
background: var(--#{$prefix}body-bg);
|
|
||||||
}
|
|
||||||
|
|
||||||
> .navbar:first-child {
|
|
||||||
border-top-left-radius: var(--#{$prefix}theme-boxed-border-radius);
|
|
||||||
border-top-right-radius: var(--#{$prefix}theme-boxed-border-radius);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,177 +0,0 @@
|
|||||||
.accordion {
|
|
||||||
--#{$prefix}accordion-color: var(--#{$prefix}body-color);
|
|
||||||
--#{$prefix}accordion-border-color: var(--#{$prefix}border-color);
|
|
||||||
--#{$prefix}accordion-border-radius: #{$accordion-border-radius};
|
|
||||||
--#{$prefix}accordion-inner-border-radius: #{$accordion-inner-border-radius};
|
|
||||||
--#{$prefix}accordion-padding-x: #{$accordion-body-padding-x};
|
|
||||||
--#{$prefix}accordion-gap: 0;
|
|
||||||
--#{$prefix}accordion-active-color: #{$accordion-button-active-color};
|
|
||||||
--#{$prefix}accordion-btn-color: var(--#{$prefix}accordion-color);
|
|
||||||
--#{$prefix}accordion-btn-bg: #{$accordion-button-bg};
|
|
||||||
--#{$prefix}accordion-btn-toggle-width: 1.25rem;
|
|
||||||
--#{$prefix}accordion-btn-padding-x: var(--#{$prefix}accordion-padding-x);
|
|
||||||
--#{$prefix}accordion-btn-padding-y: #{$accordion-button-padding-y};
|
|
||||||
--#{$prefix}accordion-btn-font-weight: var(--#{$prefix}font-weight-medium);
|
|
||||||
--#{$prefix}accordion-body-padding-x: var(--#{$prefix}accordion-padding-x);
|
|
||||||
--#{$prefix}accordion-body-padding-y: #{$accordion-body-padding-y};
|
|
||||||
|
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
gap: var(--#{$prefix}accordion-gap);
|
|
||||||
}
|
|
||||||
|
|
||||||
.accordion-button {
|
|
||||||
position: relative;
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
width: 100%;
|
|
||||||
padding: var(--#{$prefix}accordion-btn-padding-y) var(--#{$prefix}accordion-padding-x);
|
|
||||||
color: inherit;
|
|
||||||
text-align: inherit;
|
|
||||||
background-color: transparent;
|
|
||||||
border: 0;
|
|
||||||
font-size: inherit;
|
|
||||||
font-weight: var(--#{$prefix}accordion-btn-font-weight);
|
|
||||||
gap: .75rem;
|
|
||||||
|
|
||||||
&:not(.collapsed) {
|
|
||||||
border-bottom-color: transparent;
|
|
||||||
box-shadow: none;
|
|
||||||
color: var(--#{$prefix}accordion-active-color);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.accordion-header {
|
|
||||||
margin: 0;
|
|
||||||
position: relative;
|
|
||||||
display: flex;
|
|
||||||
gap: 1rem;
|
|
||||||
align-items: center;
|
|
||||||
width: 100%;
|
|
||||||
color: var(--#{$prefix}accordion-btn-color);
|
|
||||||
text-align: left;
|
|
||||||
background-color: transparent;
|
|
||||||
border: 0;
|
|
||||||
overflow-anchor: none;
|
|
||||||
transition: transform $transition-time;
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
z-index: 2;
|
|
||||||
}
|
|
||||||
|
|
||||||
&:focus {
|
|
||||||
z-index: 3;
|
|
||||||
outline: 0;
|
|
||||||
box-shadow: var(--#{$prefix}accordion-btn-focus-box-shadow);
|
|
||||||
|
|
||||||
&:not(:focus-visible) {
|
|
||||||
outline: none;
|
|
||||||
box-shadow: none;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.accordion-button-icon {
|
|
||||||
color: var(--#{$prefix}secondary);
|
|
||||||
}
|
|
||||||
|
|
||||||
.accordion-button-toggle {
|
|
||||||
display: flex;
|
|
||||||
line-height: 1;
|
|
||||||
transition: $transition-time transform;
|
|
||||||
margin-left: auto;
|
|
||||||
margin-right: 0;
|
|
||||||
color: var(--#{$prefix}secondary);
|
|
||||||
width: var(--#{$prefix}accordion-btn-toggle-width);
|
|
||||||
height: var(--#{$prefix}accordion-btn-toggle-width);
|
|
||||||
|
|
||||||
.accordion-button:not(.collapsed) & {
|
|
||||||
transform: rotate(-180deg);
|
|
||||||
color: var(--#{$prefix}accordion-active-color);
|
|
||||||
}
|
|
||||||
|
|
||||||
path {
|
|
||||||
transition: $transition-time opacity;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.accordion-button-toggle-plus {
|
|
||||||
.accordion-button:not(.collapsed) & {
|
|
||||||
path:first-child {
|
|
||||||
opacity: 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.accordion-item {
|
|
||||||
color: var(--#{$prefix}accordion-color);
|
|
||||||
border: var(--#{$prefix}border-width) solid var(--#{$prefix}accordion-border-color);
|
|
||||||
|
|
||||||
&:first-of-type {
|
|
||||||
@include border-top-radius(var(--#{$prefix}accordion-border-radius));
|
|
||||||
|
|
||||||
> .accordion-header {
|
|
||||||
@include border-top-radius(var(--#{$prefix}accordion-inner-border-radius));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
&:not(:first-of-type) {
|
|
||||||
border-top: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
&:last-of-type {
|
|
||||||
@include border-bottom-radius(var(--#{$prefix}accordion-border-radius));
|
|
||||||
|
|
||||||
> .accordion-header {
|
|
||||||
&.collapsed {
|
|
||||||
@include border-bottom-radius(var(--#{$prefix}accordion-inner-border-radius));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
> .accordion-collapse {
|
|
||||||
@include border-bottom-radius(var(--#{$prefix}accordion-border-radius));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.accordion-body {
|
|
||||||
color: var(--#{$prefix}secondary);
|
|
||||||
padding: 0 var(--#{$prefix}accordion-body-padding-x) var(--#{$prefix}accordion-body-padding-y);
|
|
||||||
}
|
|
||||||
|
|
||||||
.accordion-flush {
|
|
||||||
> .accordion-item {
|
|
||||||
border-right: 0;
|
|
||||||
border-left: 0;
|
|
||||||
@include border-radius(0);
|
|
||||||
|
|
||||||
&:first-child {
|
|
||||||
border-top: 0;
|
|
||||||
}
|
|
||||||
&:last-child {
|
|
||||||
border-bottom: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
> .accordion-collapse,
|
|
||||||
> .accordion-header .accordion-button,
|
|
||||||
> .accordion-header .accordion-button.collapsed {
|
|
||||||
@include border-radius(0);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.accordion-tabs {
|
|
||||||
--#{$prefix}accordion-gap: 0.75rem;
|
|
||||||
|
|
||||||
> .accordion-item {
|
|
||||||
border: var(--#{$prefix}border-width) solid var(--#{$prefix}accordion-border-color);
|
|
||||||
border-radius: var(--#{$prefix}accordion-border-radius);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.accordion-inverted {
|
|
||||||
.accordion-button-toggle {
|
|
||||||
order: -1;
|
|
||||||
margin-left: 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,101 +0,0 @@
|
|||||||
.alert {
|
|
||||||
// scss-docs-start alert-variables
|
|
||||||
--#{$prefix}alert-color: var(--#{$prefix}body-color);
|
|
||||||
--#{$prefix}alert-bg: #{color-transparent(var(--#{$prefix}alert-color), .1)};
|
|
||||||
--#{$prefix}alert-padding-x: #{$alert-padding-x};
|
|
||||||
--#{$prefix}alert-padding-y: #{$alert-padding-y};
|
|
||||||
--#{$prefix}alert-margin-bottom: #{$alert-margin-bottom};
|
|
||||||
--#{$prefix}alert-border-color: #{color-transparent(var(--#{$prefix}alert-color), .2)};
|
|
||||||
--#{$prefix}alert-border: var(--#{$prefix}border-width) solid var(--#{$prefix}alert-border-color);
|
|
||||||
--#{$prefix}alert-border-radius: var(--#{$prefix}border-radius);
|
|
||||||
--#{$prefix}alert-link-color: inherit;
|
|
||||||
--#{$prefix}alert-heading-font-weight: var(--#{$prefix}font-weight-medium);
|
|
||||||
// scss-docs-end
|
|
||||||
|
|
||||||
position: relative;
|
|
||||||
padding: var(--#{$prefix}alert-padding-y) var(--#{$prefix}alert-padding-x);
|
|
||||||
margin-bottom: var(--#{$prefix}alert-margin-bottom);
|
|
||||||
background-color: color-mix(in srgb, var(--#{$prefix}alert-bg), var(--#{$prefix}bg-surface));
|
|
||||||
border-radius: var(--#{$prefix}alert-border-radius);
|
|
||||||
border: var(--#{$prefix}border-width) var(--#{$prefix}border-style) var(--#{$prefix}alert-border-color);
|
|
||||||
display: flex;
|
|
||||||
flex-direction: row;
|
|
||||||
gap: 1rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.alert-heading {
|
|
||||||
color: inherit;
|
|
||||||
margin-bottom: .25rem; // todo: use variable
|
|
||||||
font-weight: var(--#{$prefix}alert-heading-font-weight);
|
|
||||||
}
|
|
||||||
|
|
||||||
.alert-description {
|
|
||||||
color: var(--#{$prefix}secondary);
|
|
||||||
}
|
|
||||||
|
|
||||||
.alert-icon {
|
|
||||||
color: var(--#{$prefix}alert-color);
|
|
||||||
width: 1.25rem !important; // todo: use variable
|
|
||||||
height: 1.25rem !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.alert-action {
|
|
||||||
color: var(--#{$prefix}alert-color);
|
|
||||||
text-decoration: underline;
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
text-decoration: none;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.alert-list {
|
|
||||||
margin: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.alert-link {
|
|
||||||
font-weight: $alert-link-font-weight;
|
|
||||||
color: var(--#{$prefix}alert-link-color);
|
|
||||||
|
|
||||||
&,
|
|
||||||
&:hover {
|
|
||||||
color: var(--#{$prefix}alert-color);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
.alert-dismissible {
|
|
||||||
padding-right: 3rem; //todo: use variable
|
|
||||||
|
|
||||||
.btn-close {
|
|
||||||
position: absolute;
|
|
||||||
top: calc(var(--#{$prefix}alert-padding-x) / 2 - 1px);
|
|
||||||
right: calc(var(--#{$prefix}alert-padding-y) / 2 - 1px);
|
|
||||||
z-index: 1;
|
|
||||||
padding: calc(var(--#{$prefix}alert-padding-y) * 1.25) var(--#{$prefix}alert-padding-x);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.alert-important {
|
|
||||||
border-color: var(--#{$prefix}alert-color);
|
|
||||||
background-color: var(--#{$prefix}alert-color);
|
|
||||||
color: var(--#{$prefix}white);
|
|
||||||
|
|
||||||
.alert-description {
|
|
||||||
color: inherit;
|
|
||||||
}
|
|
||||||
|
|
||||||
.alert-icon {
|
|
||||||
color: inherit;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.alert-minor {
|
|
||||||
background: transparent;
|
|
||||||
border-color: var(--tblr-border-color);
|
|
||||||
}
|
|
||||||
|
|
||||||
@each $name, $color in $theme-colors {
|
|
||||||
.alert-#{$name} {
|
|
||||||
--#{$prefix}alert-color: var(--#{$prefix}#{$name});
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,113 +0,0 @@
|
|||||||
.badge {
|
|
||||||
--#{$prefix}badge-padding-x: #{$badge-padding-x};
|
|
||||||
--#{$prefix}badge-padding-y: #{$badge-padding-y};
|
|
||||||
--#{$prefix}badge-font-size: #{$badge-font-size};
|
|
||||||
--#{$prefix}badge-font-weight: #{$badge-font-weight};
|
|
||||||
--#{$prefix}badge-color: #{$badge-color};
|
|
||||||
--#{$prefix}badge-border-radius: #{$badge-border-radius};
|
|
||||||
--#{$prefix}badge-icon-size: 1em;
|
|
||||||
--#{$prefix}badge-line-height: 1;
|
|
||||||
display: inline-flex;
|
|
||||||
padding: var(--#{$prefix}badge-padding-y) var(--#{$prefix}badge-padding-x);
|
|
||||||
font-weight: var(--#{$prefix}badge-font-weight);
|
|
||||||
font-size: var(--#{$prefix}badge-font-size);
|
|
||||||
color: var(--#{$prefix}badge-color);
|
|
||||||
text-align: center;
|
|
||||||
white-space: nowrap;
|
|
||||||
justify-content: center;
|
|
||||||
align-items: center;
|
|
||||||
gap: .25rem;
|
|
||||||
background: $badge-bg-color;
|
|
||||||
overflow: hidden;
|
|
||||||
user-select: none;
|
|
||||||
border: var(--#{$prefix}border-width) var(--#{$prefix}border-style) transparent;
|
|
||||||
border-radius: var(--#{$prefix}badge-border-radius);
|
|
||||||
min-width: calc(1em + var(--#{$prefix}badge-padding-y) * 2 + 2px);
|
|
||||||
letter-spacing: 0.04em;
|
|
||||||
vertical-align: bottom;
|
|
||||||
line-height: var(--#{$prefix}badge-line-height);
|
|
||||||
|
|
||||||
@at-root a#{&} {
|
|
||||||
background: var(--#{$prefix}bg-surface-secondary);
|
|
||||||
}
|
|
||||||
|
|
||||||
.icon {
|
|
||||||
width: 1em;
|
|
||||||
height: 1em;
|
|
||||||
font-size: var(--#{$prefix}badge-icon-size);
|
|
||||||
stroke-width: 2;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.badge:empty,
|
|
||||||
.badge-dot {
|
|
||||||
display: inline-block;
|
|
||||||
width: $badge-empty-size;
|
|
||||||
height: $badge-empty-size;
|
|
||||||
min-width: 0;
|
|
||||||
min-height: auto;
|
|
||||||
padding: 0;
|
|
||||||
border-radius: $border-radius-pill;
|
|
||||||
vertical-align: baseline;
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
|
||||||
// Outline badge
|
|
||||||
//
|
|
||||||
.badge-outline {
|
|
||||||
background-color: transparent;
|
|
||||||
border: var(--#{$prefix}border-width) var(--#{$prefix}border-style) currentColor;
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
|
||||||
// Pill badge
|
|
||||||
//
|
|
||||||
.badge-pill {
|
|
||||||
border-radius: $border-radius-pill;
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
|
||||||
// Badges list
|
|
||||||
//
|
|
||||||
.badges-list {
|
|
||||||
@include elements-list;
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
|
||||||
// Notification badge
|
|
||||||
//
|
|
||||||
.badge-notification {
|
|
||||||
position: absolute !important;
|
|
||||||
top: 0 !important;
|
|
||||||
right: 0 !important;
|
|
||||||
transform: translate(50%, -50%);
|
|
||||||
z-index: 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
.badge-blink {
|
|
||||||
animation: blink 2s infinite;
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
|
||||||
// Badge sizes
|
|
||||||
//
|
|
||||||
.badge-sm {
|
|
||||||
--#{$prefix}badge-font-size: #{$badge-font-size-sm};
|
|
||||||
--#{$prefix}badge-icon-size: 1em;
|
|
||||||
--#{$prefix}badge-padding-y: 2px;
|
|
||||||
--#{$prefix}badge-padding-x: 0.25rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.badge-lg {
|
|
||||||
--#{$prefix}badge-font-size: #{$badge-font-size-lg};
|
|
||||||
--#{$prefix}badge-icon-size: 1em;
|
|
||||||
--#{$prefix}badge-padding-y: 0.25rem;
|
|
||||||
--#{$prefix}badge-padding-x: 0.5rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
|
||||||
// Badge with only icon
|
|
||||||
//
|
|
||||||
.badge-icononly {
|
|
||||||
--#{$prefix}badge-padding-x: 0;
|
|
||||||
}
|
|
||||||
@@ -1,81 +0,0 @@
|
|||||||
.breadcrumb {
|
|
||||||
--#{$prefix}breadcrumb-padding-x: #{$breadcrumb-padding-x};
|
|
||||||
--#{$prefix}breadcrumb-padding-y: #{$breadcrumb-padding-y};
|
|
||||||
--#{$prefix}breadcrumb-margin-bottom: #{$breadcrumb-margin-bottom};
|
|
||||||
--#{$prefix}breadcrumb-font-size: #{$breadcrumb-font-size};
|
|
||||||
--#{$prefix}breadcrumb-bg: #{$breadcrumb-bg};
|
|
||||||
--#{$prefix}breadcrumb-border-radius: #{$breadcrumb-border-radius};
|
|
||||||
--#{$prefix}breadcrumb-divider-color: #{$breadcrumb-divider-color};
|
|
||||||
--#{$prefix}breadcrumb-item-padding-x: #{$breadcrumb-item-padding-x};
|
|
||||||
--#{$prefix}breadcrumb-item-active-color: #{$breadcrumb-active-color};
|
|
||||||
--#{$prefix}breadcrumb-item-active-font-weight: #{$breadcrumb-active-font-weight};
|
|
||||||
--#{$prefix}breadcrumb-item-disabled-color: #{$breadcrumb-disabled-color};
|
|
||||||
--#{$prefix}breadcrumb-link-color: #{$breadcrumb-link-color};
|
|
||||||
|
|
||||||
display: flex;
|
|
||||||
flex-wrap: wrap;
|
|
||||||
@include font-size(var(--#{$prefix}breadcrumb-font-size));
|
|
||||||
list-style: none;
|
|
||||||
background-color: var(--#{$prefix}breadcrumb-bg);
|
|
||||||
@include border-radius(var(--#{$prefix}breadcrumb-border-radius));
|
|
||||||
padding: 0;
|
|
||||||
margin: 0;
|
|
||||||
background: transparent;
|
|
||||||
|
|
||||||
a {
|
|
||||||
color: var(--#{$prefix}breadcrumb-link-color);
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
text-decoration: underline;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.breadcrumb-muted {
|
|
||||||
--#{$prefix}breadcrumb-link-color: var(--#{$prefix}secondary);
|
|
||||||
}
|
|
||||||
|
|
||||||
.breadcrumb-item {
|
|
||||||
&.active {
|
|
||||||
color: var(--#{$prefix}breadcrumb-item-active-color);
|
|
||||||
font-weight: var(--#{$prefix}breadcrumb-item-active-font-weight);
|
|
||||||
|
|
||||||
a {
|
|
||||||
color: inherit;
|
|
||||||
pointer-events: none;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
&.disabled {
|
|
||||||
color: var(--#{$prefix}breadcrumb-item-disabled-color);
|
|
||||||
|
|
||||||
&:before {
|
|
||||||
color: inherit;
|
|
||||||
}
|
|
||||||
|
|
||||||
a {
|
|
||||||
color: inherit;
|
|
||||||
pointer-events: none;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
& + & {
|
|
||||||
padding-left: var(--#{$prefix}breadcrumb-item-padding-x);
|
|
||||||
|
|
||||||
&::before {
|
|
||||||
float: left;
|
|
||||||
padding-right: var(--#{$prefix}breadcrumb-item-padding-x);
|
|
||||||
color: var(--#{$prefix}breadcrumb-divider-color);
|
|
||||||
content: var(--#{$prefix}breadcrumb-divider, escape-svg($breadcrumb-divider));
|
|
||||||
/*rtl:raw:
|
|
||||||
transform: scaleX(-1);
|
|
||||||
*/
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@each $name, $symbol in $breadcrumb-variants {
|
|
||||||
.breadcrumb-#{$name} {
|
|
||||||
--#{$prefix}breadcrumb-divider: "#{quote($symbol)}";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,61 +0,0 @@
|
|||||||
.btn-close {
|
|
||||||
--#{$prefix}btn-close-color: currentColor;
|
|
||||||
--#{$prefix}btn-close-bg: #{ escape-svg($btn-close-bg) };
|
|
||||||
--#{$prefix}btn-close-opacity: #{$btn-close-opacity};
|
|
||||||
--#{$prefix}btn-close-hover-opacity: #{$btn-close-hover-opacity};
|
|
||||||
--#{$prefix}btn-close-focus-shadow: #{$btn-close-focus-shadow};
|
|
||||||
--#{$prefix}btn-close-focus-opacity: #{$btn-close-focus-opacity};
|
|
||||||
--#{$prefix}btn-close-disabled-opacity: #{$btn-close-disabled-opacity};
|
|
||||||
--#{$prefix}btn-close-size: #{$btn-close-width};
|
|
||||||
|
|
||||||
width: var(--#{$prefix}btn-close-size);
|
|
||||||
height: var(--#{$prefix}btn-close-size);
|
|
||||||
padding: $btn-close-padding-y $btn-close-padding-x;
|
|
||||||
color: var(--#{$prefix}btn-close-color);
|
|
||||||
mask: var(--#{$prefix}btn-close-bg) no-repeat center/calc(var(--#{$prefix}btn-close-size) * .75);
|
|
||||||
background-color: var(--#{$prefix}btn-close-color);
|
|
||||||
border: 0;
|
|
||||||
border-radius: var(--tblr-border-radius);
|
|
||||||
opacity: var(--#{$prefix}btn-close-opacity);
|
|
||||||
cursor: pointer;
|
|
||||||
display: block;
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
color: var(--#{$prefix}btn-close-color);
|
|
||||||
text-decoration: none;
|
|
||||||
opacity: var(--#{$prefix}btn-close-hover-opacity);
|
|
||||||
background-color: var(--#{$prefix}btn-close-color);
|
|
||||||
}
|
|
||||||
|
|
||||||
&:focus {
|
|
||||||
outline: 0;
|
|
||||||
box-shadow: var(--#{$prefix}btn-close-focus-shadow);
|
|
||||||
opacity: var(--#{$prefix}btn-close-focus-opacity);
|
|
||||||
}
|
|
||||||
|
|
||||||
&:disabled,
|
|
||||||
&.disabled {
|
|
||||||
pointer-events: none;
|
|
||||||
user-select: none;
|
|
||||||
opacity: var(--#{$prefix}btn-close-disabled-opacity);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// @mixin btn-close-white() {
|
|
||||||
// --#{$prefix}btn-close-filter: #{$btn-close-filter-dark};
|
|
||||||
// }
|
|
||||||
|
|
||||||
// .btn-close-white {
|
|
||||||
// @include btn-close-white();
|
|
||||||
// }
|
|
||||||
|
|
||||||
// :root,
|
|
||||||
// [data-bs-theme="light"] {
|
|
||||||
// --#{$prefix}btn-close-filter: #{$btn-close-filter};
|
|
||||||
// }
|
|
||||||
|
|
||||||
// @if $enable-dark-mode {
|
|
||||||
// @include color-mode(dark, true) {
|
|
||||||
// @include btn-close-white();
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
@@ -1,101 +0,0 @@
|
|||||||
.nav-segmented {
|
|
||||||
--#{$prefix}nav-bg: var(--#{$prefix}bg-surface-tertiary);
|
|
||||||
--#{$prefix}nav-padding: 2px;
|
|
||||||
--#{$prefix}nav-height: 2.5rem;
|
|
||||||
--#{$prefix}nav-gap: .25rem;
|
|
||||||
--#{$prefix}nav-active-bg: var(--#{$prefix}bg-surface);
|
|
||||||
--#{$prefix}nav-font-size: inherit;
|
|
||||||
--#{$prefix}nav-radius: 6px;
|
|
||||||
|
|
||||||
|
|
||||||
--#{$prefix}nav-link-disabled-color: var(--#{$prefix}disabled-color);
|
|
||||||
--#{$prefix}nav-link-gap: .25rem;
|
|
||||||
--#{$prefix}nav-link-padding-x: .75rem;
|
|
||||||
--#{$prefix}nav-link-icon-size: 1.25rem;
|
|
||||||
display: inline-flex;
|
|
||||||
flex-wrap: wrap;
|
|
||||||
gap: var(--#{$prefix}nav-gap);
|
|
||||||
padding: var(--#{$prefix}nav-padding);
|
|
||||||
list-style: none;
|
|
||||||
background: var(--#{$prefix}nav-bg);
|
|
||||||
border-radius: calc(var(--#{$prefix}nav-radius) + var(--#{$prefix}nav-padding));
|
|
||||||
box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .04);
|
|
||||||
|
|
||||||
.nav-link {
|
|
||||||
display: inline-flex;
|
|
||||||
gap: calc(.25rem + var(--#{$prefix}nav-link-gap));
|
|
||||||
align-items: center;
|
|
||||||
margin: 0;
|
|
||||||
font-size: var(--#{$prefix}nav-font-size);
|
|
||||||
min-width: calc(var(--#{$prefix}nav-height) - 2 * var(--#{$prefix}nav-padding));
|
|
||||||
height: calc(var(--#{$prefix}nav-height) - 2 * var(--#{$prefix}nav-padding));
|
|
||||||
padding: 0 calc(var(--#{$prefix}nav-link-padding-x) - 2px);
|
|
||||||
border: 1px solid transparent;
|
|
||||||
background: transparent;
|
|
||||||
color: var(--#{$prefix}secondary);
|
|
||||||
text-align: center;
|
|
||||||
text-decoration: none;
|
|
||||||
white-space: nowrap;
|
|
||||||
cursor: pointer;
|
|
||||||
transition: background-color $transition-time, color $transition-time;
|
|
||||||
border-radius: var(--#{$prefix}nav-radius);
|
|
||||||
flex-grow: 1;
|
|
||||||
justify-content: center;
|
|
||||||
|
|
||||||
&:hover,
|
|
||||||
&.hover {
|
|
||||||
background: rgba(0, 0, 0, .04);
|
|
||||||
color: var(--#{$prefix}body-color);
|
|
||||||
}
|
|
||||||
|
|
||||||
&.disabled,
|
|
||||||
&:disabled {
|
|
||||||
color: var(--#{$prefix}nav-link-disabled-color);
|
|
||||||
cursor: not-allowed;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.nav-link-input:checked + .nav-link,
|
|
||||||
.nav-link.active {
|
|
||||||
color: var(--#{$prefix}body-color);
|
|
||||||
background: var(--#{$prefix}nav-active-bg);
|
|
||||||
border-color: var(--#{$prefix}border-color);
|
|
||||||
}
|
|
||||||
|
|
||||||
.nav-link-input {
|
|
||||||
display: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.nav-link-icon {
|
|
||||||
width: var(--#{$prefix}nav-link-icon-size);
|
|
||||||
height: var(--#{$prefix}nav-link-icon-size);
|
|
||||||
margin: 0 -.25rem;
|
|
||||||
color: inherit;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.nav-segmented-vertical {
|
|
||||||
flex-direction: column;
|
|
||||||
|
|
||||||
.nav-link {
|
|
||||||
justify-content: flex-start;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.nav-sm {
|
|
||||||
--#{$prefix}nav-height: 2rem;
|
|
||||||
--#{$prefix}nav-font-size: var(--tblr-font-size-h5);
|
|
||||||
--#{$prefix}nav-radius: 4px;
|
|
||||||
--#{$prefix}nav-link-padding-x: .5rem;
|
|
||||||
--#{$prefix}nav-link-gap: .25rem;
|
|
||||||
--#{$prefix}nav-link-icon-size: 1rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.nav-lg {
|
|
||||||
--#{$prefix}nav-height: 3rem;
|
|
||||||
--#{$prefix}nav-font-size: var(--tblr-font-size-h3);
|
|
||||||
--#{$prefix}nav-radius: 8px;
|
|
||||||
--#{$prefix}nav-link-padding-x: 1rem;
|
|
||||||
--#{$prefix}nav-link-gap: .5rem;
|
|
||||||
--#{$prefix}nav-link-icon-size: 1.5rem;
|
|
||||||
}
|
|
||||||
@@ -1,15 +0,0 @@
|
|||||||
.signature {
|
|
||||||
--#{$prefix}signature-padding: var(--#{$prefix}spacer-1);
|
|
||||||
--#{$prefix}signature-border-radius: var(--#{$prefix}border-radius);
|
|
||||||
border: var(--#{$prefix}border-width) solid var(--#{$prefix}border-color);
|
|
||||||
padding: var(--#{$prefix}signature-padding);
|
|
||||||
border-radius: var(--#{$prefix}border-radius);
|
|
||||||
}
|
|
||||||
|
|
||||||
.signature-canvas {
|
|
||||||
border: var(--#{$prefix}border-width) dashed var(--#{$prefix}border-color);
|
|
||||||
border-radius: calc(var(--#{$prefix}signature-border-radius) - var(--#{$prefix}signature-padding));
|
|
||||||
display: block;
|
|
||||||
cursor: crosshair;
|
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
@@ -1,330 +0,0 @@
|
|||||||
@import "typo/hr";
|
|
||||||
|
|
||||||
.lead {
|
|
||||||
color: var(--#{$prefix}secondary);
|
|
||||||
font-size: inherit;
|
|
||||||
}
|
|
||||||
|
|
||||||
a {
|
|
||||||
text-decoration-skip-ink: auto;
|
|
||||||
color: color-mix(in srgb, transparent, var(--#{$prefix}link-color) var(--#{$prefix}link-opacity, 100%));
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
color: color-mix(in srgb, transparent, var(--#{$prefix}link-hover-color) var(--#{$prefix}link-opacity, 100%));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
h1,
|
|
||||||
h2,
|
|
||||||
h3,
|
|
||||||
h4,
|
|
||||||
h5,
|
|
||||||
h6,
|
|
||||||
.h1,
|
|
||||||
.h2,
|
|
||||||
.h3,
|
|
||||||
.h4,
|
|
||||||
.h5,
|
|
||||||
.h6 {
|
|
||||||
a {
|
|
||||||
color: inherit;
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
color: inherit;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
h1,
|
|
||||||
.h1 {
|
|
||||||
font-size: var(--#{$prefix}font-size-h1);
|
|
||||||
line-height: var(--#{$prefix}line-height-h1);
|
|
||||||
}
|
|
||||||
|
|
||||||
h2,
|
|
||||||
.h2 {
|
|
||||||
font-size: var(--#{$prefix}font-size-h2);
|
|
||||||
line-height: var(--#{$prefix}line-height-h2);
|
|
||||||
}
|
|
||||||
|
|
||||||
h3,
|
|
||||||
.h3 {
|
|
||||||
font-size: var(--#{$prefix}font-size-h3);
|
|
||||||
line-height: var(--#{$prefix}line-height-h3);
|
|
||||||
}
|
|
||||||
|
|
||||||
h4,
|
|
||||||
.h4 {
|
|
||||||
font-size: var(--#{$prefix}font-size-h4);
|
|
||||||
line-height: var(--#{$prefix}line-height-h4);
|
|
||||||
}
|
|
||||||
|
|
||||||
h5,
|
|
||||||
.h5 {
|
|
||||||
font-size: var(--#{$prefix}font-size-h5);
|
|
||||||
line-height: var(--#{$prefix}line-height-h5);
|
|
||||||
}
|
|
||||||
|
|
||||||
h6,
|
|
||||||
.h6 {
|
|
||||||
font-size: var(--#{$prefix}font-size-h6);
|
|
||||||
line-height: var(--#{$prefix}line-height-h6);
|
|
||||||
}
|
|
||||||
|
|
||||||
.fs-base {
|
|
||||||
font-size: var(--#{$prefix}body-font-size);
|
|
||||||
}
|
|
||||||
|
|
||||||
strong,
|
|
||||||
.strong,
|
|
||||||
b {
|
|
||||||
font-weight: $headings-font-weight;
|
|
||||||
}
|
|
||||||
|
|
||||||
blockquote {
|
|
||||||
padding: 1rem 1rem 1rem;
|
|
||||||
border-left: 2px var(--#{$prefix}border-style) var(--#{$prefix}border-color);
|
|
||||||
|
|
||||||
p {
|
|
||||||
margin-bottom: 1rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
cite {
|
|
||||||
display: block;
|
|
||||||
text-align: right;
|
|
||||||
|
|
||||||
&:before {
|
|
||||||
content: "— ";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
ul,
|
|
||||||
ol {
|
|
||||||
padding-left: 1.5rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
hr {
|
|
||||||
margin: 2rem 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
dl {
|
|
||||||
dd {
|
|
||||||
&:last-child {
|
|
||||||
margin-bottom: 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
pre {
|
|
||||||
--#{$prefix}scrollbar-color: #{$pre-color};
|
|
||||||
padding: $pre-padding;
|
|
||||||
background: $pre-bg;
|
|
||||||
color: $pre-color;
|
|
||||||
border-radius: var(--#{$prefix}border-radius);
|
|
||||||
line-height: $line-height-base;
|
|
||||||
|
|
||||||
@include scrollbar;
|
|
||||||
|
|
||||||
code {
|
|
||||||
background: transparent;
|
|
||||||
padding: 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
code {
|
|
||||||
background: var(--#{$prefix}code-bg);
|
|
||||||
padding: 2px 4px;
|
|
||||||
border-radius: var(--#{$prefix}border-radius);
|
|
||||||
}
|
|
||||||
|
|
||||||
abbr {
|
|
||||||
text-decoration: underline dotted;
|
|
||||||
cursor: help;
|
|
||||||
text-decoration-skip-ink: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
kbd,
|
|
||||||
.kbd {
|
|
||||||
border: $kbd-border;
|
|
||||||
display: inline-block;
|
|
||||||
box-sizing: border-box;
|
|
||||||
max-width: 100%;
|
|
||||||
font-size: $kbd-font-size;
|
|
||||||
font-weight: $kbd-font-weight;
|
|
||||||
line-height: 1;
|
|
||||||
vertical-align: baseline;
|
|
||||||
border-radius: $kbd-border-radius;
|
|
||||||
}
|
|
||||||
|
|
||||||
img {
|
|
||||||
max-width: 100%;
|
|
||||||
height: auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
.list-unstyled {
|
|
||||||
margin-left: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
Selection
|
|
||||||
*/
|
|
||||||
::selection,
|
|
||||||
.text-selected {
|
|
||||||
background-color: color-transparent(var(--#{$prefix}primary), 0.1);
|
|
||||||
}
|
|
||||||
|
|
||||||
.text-selected {
|
|
||||||
display: inline-block;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
Links
|
|
||||||
*/
|
|
||||||
[class^="link-"],
|
|
||||||
[class*=" link-"] {
|
|
||||||
&.disabled {
|
|
||||||
color: $nav-link-disabled-color !important;
|
|
||||||
pointer-events: none;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
a:hover:has(.icon) {
|
|
||||||
text-decoration: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.link-hoverable {
|
|
||||||
border-radius: var(--#{$prefix}border-radius);
|
|
||||||
transition: background-color 0.15s ease-in-out;
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
text-decoration: none;
|
|
||||||
color: var(--#{$prefix}primary);
|
|
||||||
background: color-transparent(var(--#{$prefix}secondary), 0.04);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
Subheader
|
|
||||||
*/
|
|
||||||
.subheader {
|
|
||||||
@include subheader;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
Mentions
|
|
||||||
*/
|
|
||||||
.mention {
|
|
||||||
display: inline-block;
|
|
||||||
box-shadow: var(--#{$prefix}shadow-border);
|
|
||||||
border-radius: var(--#{$prefix}border-radius-pill);
|
|
||||||
line-height: calc(16em / 12);
|
|
||||||
font-size: calc(12em / 14);
|
|
||||||
color: var(--#{$prefix}body-color);
|
|
||||||
background: var(--#{$prefix}bg-surface-tertiary);
|
|
||||||
padding: calc(2em / 12) calc(8em / 12);
|
|
||||||
font-weight: var(--#{$prefix}font-weight-medium);
|
|
||||||
|
|
||||||
@at-root a#{&} {
|
|
||||||
cursor: pointer;
|
|
||||||
|
|
||||||
&:hover,
|
|
||||||
&.hover {
|
|
||||||
background: var(--#{$prefix}bg-surface-secondary);
|
|
||||||
text-decoration: underline;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.mention-avatar,
|
|
||||||
.mention-app,
|
|
||||||
.mention-color {
|
|
||||||
width: calc(14em / 12);
|
|
||||||
height: calc(14em / 12);
|
|
||||||
border-radius: var(--#{$prefix}border-radius-pill);
|
|
||||||
margin: calc(-2em / 12) calc(4em / 12) 0 calc(-4em / 12);
|
|
||||||
display: inline-flex;
|
|
||||||
background: no-repeat center center/cover;
|
|
||||||
box-shadow: var(--#{$prefix}shadow-border);
|
|
||||||
vertical-align: middle;
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
.mention-app {
|
|
||||||
box-shadow: none;
|
|
||||||
background: none;
|
|
||||||
border-radius: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.mention-count {
|
|
||||||
color: var(--#{$prefix}secondary);
|
|
||||||
margin-left: calc(8em / 12);
|
|
||||||
}
|
|
||||||
|
|
||||||
$text-variants: (
|
|
||||||
incorrect: var(--#{$prefix}red),
|
|
||||||
correct: var(--#{$prefix}green),
|
|
||||||
);
|
|
||||||
|
|
||||||
@each $variant, $color in $text-variants {
|
|
||||||
.text-#{$variant} {
|
|
||||||
background: color-transparent($color, 0.04);
|
|
||||||
background: color-transparent($color, 4%);
|
|
||||||
text-decoration: underline;
|
|
||||||
text-decoration-thickness: 1px;
|
|
||||||
text-decoration-color: $color;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.steps {
|
|
||||||
--#{$prefix}steps-padding: 2rem;
|
|
||||||
--#{$prefix}steps-item-size: 1.5rem;
|
|
||||||
margin-left: 1rem;
|
|
||||||
padding-left: var(--#{$prefix}steps-padding);
|
|
||||||
counter-reset: step;
|
|
||||||
border-left: 1px solid var(--#{$prefix}border-color);
|
|
||||||
margin-bottom: 2rem;
|
|
||||||
|
|
||||||
h3 {
|
|
||||||
counter-increment: step;
|
|
||||||
|
|
||||||
&:not(:first-child) {
|
|
||||||
margin-top: 2.5rem !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
&:before {
|
|
||||||
content: counter(step);
|
|
||||||
display: inline-block;
|
|
||||||
position: absolute;
|
|
||||||
margin-top: 1px;
|
|
||||||
margin-left: calc(-1 * var(--#{$prefix}steps-padding) - var(--#{$prefix}steps-item-size) / 2);
|
|
||||||
width: var(--#{$prefix}steps-item-size);
|
|
||||||
height: var(--#{$prefix}steps-item-size);
|
|
||||||
text-align: center;
|
|
||||||
color: var(--#{$prefix}body-color);
|
|
||||||
border: 1px solid var(--#{$prefix}border-color);
|
|
||||||
background: var(--#{$prefix}bg-surface);
|
|
||||||
border-radius: var(--#{$prefix}border-radius);
|
|
||||||
line-height: calc(var(--#{$prefix}steps-item-size) - 2px);
|
|
||||||
font-size: var(--#{$prefix}font-size-h4);
|
|
||||||
font-weight: var(--#{$prefix}font-weight-bold);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
>:last-child {
|
|
||||||
margin-bottom: 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
.callout {
|
|
||||||
margin-bottom: 1.5rem;
|
|
||||||
border: 1px solid var(--#{$prefix}primary-200);
|
|
||||||
border-radius: var(--#{$prefix}border-radius);
|
|
||||||
padding: .5rem 1rem;
|
|
||||||
background: var(--#{$prefix}primary-lt);
|
|
||||||
|
|
||||||
&>:last-child {
|
|
||||||
margin-bottom: 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,102 +0,0 @@
|
|||||||
@use "sass:map";
|
|
||||||
|
|
||||||
// All colors
|
|
||||||
@each $color, $value in map.merge($theme-colors, ( white: $white)) {
|
|
||||||
.bg-#{"" + $color} {
|
|
||||||
background-color: color-mix(in srgb, var(--#{$prefix}#{$color}) calc(var(--#{$prefix}bg-opacity, 1) * 100%), transparent) !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.bg-#{"" + $color}-lt {
|
|
||||||
color: color-mix(in srgb, var(--#{$prefix}#{$color}) calc(var(--#{$prefix}text-opacity, 1) * 100%), transparent) !important;
|
|
||||||
background-color: color-mix(in srgb, var(--#{$prefix}#{$color}-lt) calc(var(--#{$prefix}bg-opacity, 1) * 100%), transparent) !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.border-#{"" + $color} {
|
|
||||||
border-color: color-mix(in srgb, var(--#{$prefix}#{$color}) calc(var(--#{$prefix}border-opacity, 1) * 100%), transparent) !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.bg-gradient-from-#{"" + $color} {
|
|
||||||
--#{$prefix}gradient-from: var(--#{$prefix}#{$color});
|
|
||||||
}
|
|
||||||
|
|
||||||
.bg-gradient-to-#{"" + $color} {
|
|
||||||
--#{$prefix}gradient-to: var(--#{$prefix}#{$color});
|
|
||||||
}
|
|
||||||
|
|
||||||
.bg-gradient-via-#{"" + $color} {
|
|
||||||
--#{$prefix}gradient-via: var(--#{$prefix}#{$color});
|
|
||||||
--#{$prefix}gradient-stops: var(--#{$prefix}gradient-from, transparent), var(--#{$prefix}gradient-via, transparent), var(--#{$prefix}gradient-to, transparent);
|
|
||||||
}
|
|
||||||
|
|
||||||
.text-bg-#{"" + $color} {
|
|
||||||
color: color-contrast($value) if($enable-important-utilities, !important, null);
|
|
||||||
background-color: RGBA(var(--#{$prefix}#{$color}-rgb), var(--#{$prefix}bg-opacity, 1)) if($enable-important-utilities, !important, null);
|
|
||||||
}
|
|
||||||
|
|
||||||
.link-#{"" + $color} {
|
|
||||||
color: color-mix(in srgb, var(--#{$prefix}#{$color}) calc(var(--#{$prefix}link-opacity, 1) * 100%), transparent) !important;
|
|
||||||
text-decoration-color: color-mix(in srgb, var(--#{$prefix}#{$color}) calc(var(--#{$prefix}link-underline-opacity, 1) * 100%), transparent) !important;
|
|
||||||
|
|
||||||
@if $link-shade-percentage != 0 {
|
|
||||||
&:hover,
|
|
||||||
&:focus {
|
|
||||||
$hover-color: if(color-contrast($value) == $color-contrast-light, shade-color($value, $link-shade-percentage), tint-color($value, $link-shade-percentage));
|
|
||||||
color: RGBA(#{to-rgb($hover-color)}, var(--#{$prefix}link-opacity, 1)) if($enable-important-utilities, !important, null);
|
|
||||||
text-decoration-color: RGBA(to-rgb($hover-color), var(--#{$prefix}link-underline-opacity, 1)) if($enable-important-utilities, !important, null);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@each $color, $value in $theme-colors {
|
|
||||||
.text-#{"" + $color} {
|
|
||||||
--#{$prefix}text-opacity: 1;
|
|
||||||
color: color-mix(in srgb, var(--#{$prefix}#{$color}) calc(var(--#{$prefix}text-opacity) * 100%), transparent) !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.text-#{"" + $color}-fg {
|
|
||||||
color: var(--#{$prefix}#{$color}-fg) !important;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@each $color, $value in $gray-colors {
|
|
||||||
.bg-#{"" + $color} {
|
|
||||||
--#{$prefix}bg-opacity: 1;
|
|
||||||
background-color: color-mix(in srgb, var(--#{$prefix}#{$color}) calc(var(--#{$prefix}bg-opacity) * 100%), transparent) !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.text-#{"" + $color}-fg {
|
|
||||||
color: var(--#{$prefix}#{$color}-fg) !important;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@each $color, $value in $social-colors {
|
|
||||||
.bg-#{"" + $color} {
|
|
||||||
--#{$prefix}bg-opacity: 1;
|
|
||||||
background-color: color-mix(in srgb, var(--#{$prefix}#{$color}) calc(var(--#{$prefix}bg-opacity) * 100%), transparent) !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.text-#{"" + $color}-fg {
|
|
||||||
color: var(--#{$prefix}#{$color}-fg) !important;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.bg-inverted {
|
|
||||||
--#{$prefix}bg-opacity: 1;
|
|
||||||
background-color: color-mix(in srgb, var(--#{$prefix}bg-surface-inverted) calc(var(--#{$prefix}bg-opacity) * 100%), transparent) !important;
|
|
||||||
}
|
|
||||||
.bg-surface {
|
|
||||||
background-color: var(--#{$prefix}bg-surface) !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.bg-surface-secondary {
|
|
||||||
background-color: var(--#{$prefix}bg-surface-secondary) !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.bg-surface-tertiary {
|
|
||||||
background-color: var(--#{$prefix}bg-surface-tertiary) !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.bg-surface-backdrop {
|
|
||||||
background-color: color-transparent($modal-backdrop-bg, $modal-backdrop-opacity) !important;
|
|
||||||
}
|
|
||||||
@@ -1,47 +0,0 @@
|
|||||||
%hover-animation {
|
|
||||||
transition: transform 0.3s ease;
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
will-change: transform;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.hover-elevate-up {
|
|
||||||
@extend %hover-animation;
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
transform: translateY(-4px);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.hover-elevate-down {
|
|
||||||
@extend %hover-animation;
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
transform: translateY(4px);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.hover-scale {
|
|
||||||
@extend %hover-animation;
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
transform: scale(1.1);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.hover-rotate-end {
|
|
||||||
@extend %hover-animation;
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
transform: rotate(4deg);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.hover-rotate-start {
|
|
||||||
@extend %hover-animation;
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
transform: rotate(-4deg);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
55
core/scss/vendor/_fullcalendar.scss
vendored
55
core/scss/vendor/_fullcalendar.scss
vendored
@@ -1,55 +0,0 @@
|
|||||||
:root {
|
|
||||||
--fc-border-color: var(--#{$prefix}border-color);
|
|
||||||
--fc-daygrid-event-dot-width: 5px;
|
|
||||||
|
|
||||||
--fc-event-bg-color: var(--#{$prefix}primary-lt);
|
|
||||||
--fc-event-border-color: var(--#{$prefix}primary-200);
|
|
||||||
--fc-event-text-color: var(--#{$prefix}body-color);
|
|
||||||
}
|
|
||||||
|
|
||||||
.fc-toolbar-title {
|
|
||||||
font-size: var(--#{$prefix}font-size-h3) !important;
|
|
||||||
font-weight: var(--#{$prefix}font-weight-medium);
|
|
||||||
}
|
|
||||||
|
|
||||||
.fc-daygrid-dot-event {
|
|
||||||
background-color: var(--fc-event-bg-color);
|
|
||||||
border: 1px solid var(--fc-event-border-color);
|
|
||||||
color: var(--fc-event-text-color);
|
|
||||||
padding-top: 1px;
|
|
||||||
padding-bottom: 1px;
|
|
||||||
|
|
||||||
.fc-event-title {
|
|
||||||
font-weight: inherit;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.fc-col-header-cell {
|
|
||||||
background-color: var(--#{$prefix}bg-surface-secondary);
|
|
||||||
color: var(--#{$prefix}secondary);
|
|
||||||
text-transform: uppercase;
|
|
||||||
font-weight: var(--#{$prefix}font-weight-medium);
|
|
||||||
font-size: var(--#{$prefix}font-size-h5);
|
|
||||||
padding-top: .5rem !important;
|
|
||||||
padding-bottom: .5rem !important;
|
|
||||||
line-height: 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
.fc-event-time {
|
|
||||||
font-weight: var(--#{$prefix}font-weight-bold) !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.fc-col-header-cell-cushion {
|
|
||||||
color: inherit;
|
|
||||||
}
|
|
||||||
|
|
||||||
.fc-daygrid-day-number {
|
|
||||||
color: var(--#{$prefix}secondary);
|
|
||||||
}
|
|
||||||
|
|
||||||
.fc-button {
|
|
||||||
color: var(--#{$prefix}body-color) !important;
|
|
||||||
background-color: transparent !important;
|
|
||||||
border-color: var(--#{$prefix}border-color) !important;
|
|
||||||
font-weight: var(--#{$prefix}font-weight-medium) !important;
|
|
||||||
}
|
|
||||||
3
core/scss/vendor/_turbo.scss
vendored
3
core/scss/vendor/_turbo.scss
vendored
@@ -1,3 +0,0 @@
|
|||||||
.turbo-progress-bar {
|
|
||||||
background: var(--#{$prefix}primary);
|
|
||||||
}
|
|
||||||
@@ -1,40 +0,0 @@
|
|||||||
import path from 'node:path'
|
|
||||||
import { fileURLToPath } from 'node:url'
|
|
||||||
import { babel } from '@rollup/plugin-babel'
|
|
||||||
import { nodeResolve } from '@rollup/plugin-node-resolve'
|
|
||||||
import replace from '@rollup/plugin-replace'
|
|
||||||
import dotenv from "rollup-plugin-dotenv"
|
|
||||||
|
|
||||||
const __dirname = path.dirname(fileURLToPath(import.meta.url))
|
|
||||||
|
|
||||||
const external = []
|
|
||||||
const plugins = [
|
|
||||||
dotenv({
|
|
||||||
cwd: path.resolve(__dirname, '../..'),
|
|
||||||
}),
|
|
||||||
babel({
|
|
||||||
exclude: 'node_modules/**',
|
|
||||||
babelHelpers: 'bundled'
|
|
||||||
}),
|
|
||||||
replace({
|
|
||||||
'process.env.NODE_ENV': '"production"',
|
|
||||||
preventAssignment: true
|
|
||||||
}),
|
|
||||||
nodeResolve()
|
|
||||||
]
|
|
||||||
|
|
||||||
const rollupConfig = {
|
|
||||||
input: [
|
|
||||||
path.resolve(__dirname, `../js/docs.js`)
|
|
||||||
],
|
|
||||||
output: {
|
|
||||||
name: 'docs',
|
|
||||||
dir: path.resolve(__dirname, `../dist/js`),
|
|
||||||
format: 'esm',
|
|
||||||
generatedCode: 'es2015'
|
|
||||||
},
|
|
||||||
external,
|
|
||||||
plugins
|
|
||||||
}
|
|
||||||
|
|
||||||
export default rollupConfig
|
|
||||||
1
docs/.gitignore
vendored
1
docs/.gitignore
vendored
@@ -1 +0,0 @@
|
|||||||
.vercel
|
|
||||||
@@ -1,46 +0,0 @@
|
|||||||
# Tabler Documentation Changelog
|
|
||||||
|
|
||||||
## 1.4.0
|
|
||||||
|
|
||||||
### Patch Changes
|
|
||||||
|
|
||||||
- 6c38a48: Update Bootstrap to v5.3.7
|
|
||||||
- 6c47b5f: Change `package.json` to `core/libs.json` as a source of libraries
|
|
||||||
- 70a41e4: Replace a package list in `download.md` with a link to the 3rd-party libraries page
|
|
||||||
- Updated dependencies [6c4dd36]
|
|
||||||
- Updated dependencies [6fec73a]
|
|
||||||
- Updated dependencies [9951fe9]
|
|
||||||
- Updated dependencies [db6200a]
|
|
||||||
- Updated dependencies [e96f055]
|
|
||||||
- Updated dependencies [a200d30]
|
|
||||||
- Updated dependencies [6c38a48]
|
|
||||||
- Updated dependencies [2a12f72]
|
|
||||||
- Updated dependencies [49ab9ea]
|
|
||||||
- Updated dependencies [666a296]
|
|
||||||
- Updated dependencies [cfd4cb6]
|
|
||||||
- @tabler/core@1.4.0
|
|
||||||
|
|
||||||
## 1.3.0
|
|
||||||
|
|
||||||
### Patch Changes
|
|
||||||
|
|
||||||
- 8f70185: Improve Introduction, Base, Layout and Plugins sections in documentation
|
|
||||||
- e546706: Fix input mask example in docs
|
|
||||||
- 8850f61: Enhance pagination component with new styles
|
|
||||||
- 8470c9b: Fix broken links to other docs section and tabler.io website; improve some labels.
|
|
||||||
- 6a3513f: Fix links in Tabler Emails introduction, improve "How to contribute" and other small fixes
|
|
||||||
- 278967b: Fix switch icon examples with filled icons in documentation
|
|
||||||
- 38ea9aa: Use primary color for `::selection` inside `<code>` in docs
|
|
||||||
- 5b3e201: Fix documentation: remove duplicated code examples; increase height of dropdown examples; fix some links
|
|
||||||
- 7b72653: Fix ribbon component in the documentation
|
|
||||||
- c42b104: Fix incorrect label text on form elements docs page
|
|
||||||
- 895f943: Use tabs-package include to show webfont install steps
|
|
||||||
- 665472c: Demonstrate sticky header table more clearly in docs
|
|
||||||
- 7917f86: Replace non-existent Vimeo file and enhance the inline player documentation
|
|
||||||
- 7fc1d5c: Exclude headings in the carousel and modal examples from ToC
|
|
||||||
- 7773ff2: Exclude headings inside `.example` from the Table of Contents
|
|
||||||
- 222ddd4: Change WYSIWYG title to uppercase
|
|
||||||
- 9b15b94: Add missing `.steps-vertical` classes in docs
|
|
||||||
- 5fa662b: Use color-input examples in documentation
|
|
||||||
- 5619b2d: Fix `src` links to images in README and getting-started docs page
|
|
||||||
- f8075f6: Add documentation for 3rd-party libraries and resources
|
|
||||||
@@ -1,6 +0,0 @@
|
|||||||
export default {
|
|
||||||
layout: 'docs/default',
|
|
||||||
permalink: function ({page}) {
|
|
||||||
return `${page.filePathStem.replace(/^\/content\//, '/').replace(/\/index$/, '') }/index.html`;
|
|
||||||
},
|
|
||||||
};
|
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
---
|
|
||||||
title: Tabler Emails
|
|
||||||
seoTitle: Tabler Emails - premium email templates
|
|
||||||
order: 4
|
|
||||||
description: Customizable email templates for over 90 clients and devices.
|
|
||||||
summary: Tabler Emails is a set of 80 eye-catching, customizable HTML templates. They are compatible with over 90 email clients and devices.
|
|
||||||
seoDescription: Tabler Emails is a collection of 80 premium, customizable HTML templates. They are compatible with over 90 email clients and devices.
|
|
||||||
---
|
|
||||||
@@ -1,29 +0,0 @@
|
|||||||
---
|
|
||||||
title: Compiled templates
|
|
||||||
order: 2
|
|
||||||
seoTitle: Tabler Emails - How to use the compiled HTML email templates
|
|
||||||
description: Learn how to use the compiled HTML email templates from the Tabler Emails package.
|
|
||||||
summary: The compiled HTML files from the Tabler Emails package are ready to use in your email marketing campaigns. This guide explains how to use them effectively.
|
|
||||||
seoDescription: The compiled HTML files from the Tabler Emails package are ready to use in your email marketing campaigns. This guide explains how to use them effectively.
|
|
||||||
---
|
|
||||||
|
|
||||||
## Compiled version of the template
|
|
||||||
|
|
||||||
If you only want to change content (text or images) of the email template, you can just use the compiled HTML files - `compiled.html`. They are ready to use, and you need only a basic knowledge of HTML to modify them.
|
|
||||||
|
|
||||||
## How to modify the compiled HTML files
|
|
||||||
|
|
||||||
1. Open the `compiled.html` file in your favorite code editor.
|
|
||||||
2. Find the content you want to change inside the `<body>` element.
|
|
||||||
3. Modify the content as needed:
|
|
||||||
* Change the text, which is mostly placed inside the `<p>` or `<h1>` tags.
|
|
||||||
* Change the images by replacing the `src` attribute of the `<img>` tag.
|
|
||||||
* Change the links by replacing the `href` attribute of the `<a>` tag.
|
|
||||||
* Remove the HTML elements you don't need, but only if you're sure that they are not necessary for the email template to work correctly.
|
|
||||||
4. If you changed the images, make sure to replace them in the `assets/` folder.
|
|
||||||
5. Remove all the images you don't use from `assets/` to reduce the size of the email template.
|
|
||||||
|
|
||||||
## How to use the compiled HTML files
|
|
||||||
|
|
||||||
After changing the templates as needed, you can use them in your email campaigns.
|
|
||||||
The `compiled.html` file with the `assets/` folder should be sent to your email marketing tool, like Mailchimp, SendGrid, or any other.
|
|
||||||
@@ -1,65 +0,0 @@
|
|||||||
---
|
|
||||||
title: Contents
|
|
||||||
order: 1
|
|
||||||
seoTitle: Tabler Emails - Content of the package
|
|
||||||
description: Content of the Tabler Emails package.
|
|
||||||
summary: The Tabler Emails package contains files which can be used by everyone, even without great knowledge of HTML.
|
|
||||||
seoDescription: todo
|
|
||||||
---
|
|
||||||
|
|
||||||
## Folder structure
|
|
||||||
|
|
||||||
Once you unzip the downloaded file, you will see the following structure:
|
|
||||||
|
|
||||||
```
|
|
||||||
tabler-emails/
|
|
||||||
├── emails/
|
|
||||||
| ├── absence/
|
|
||||||
| | ├── assets/
|
|
||||||
| | ├── compiled.html
|
|
||||||
| | ├── compiled-dark.html
|
|
||||||
| | ├── source.html
|
|
||||||
| | ├── source-dark.html
|
|
||||||
| | ├── screenshot.jpg
|
|
||||||
| | ├── screenshot-dark.jpg
|
|
||||||
| | ├── screenshot-mobile.jpg
|
|
||||||
| | └── screenshot-mobile-dark.jpg
|
|
||||||
| ├── access-token/
|
|
||||||
| ├── account-deleted/
|
|
||||||
| ├── .../
|
|
||||||
| ├── welcome/
|
|
||||||
| └── whishlist/
|
|
||||||
├── images/
|
|
||||||
| ├── chart-donuts/
|
|
||||||
| ├── icons/
|
|
||||||
| ├── illustrations/
|
|
||||||
| └── overlays/
|
|
||||||
├── license.txt
|
|
||||||
└── readme.html
|
|
||||||
```
|
|
||||||
|
|
||||||
## Understanding the file structure in Tabler Emails
|
|
||||||
|
|
||||||
The **Tabler Emails** package is organized into a clear and efficient folder structure to streamline the use of its assets. Below is a breakdown of its key directories:
|
|
||||||
|
|
||||||
### 1. Email Templates: `emails/`
|
|
||||||
This folder contains {{ emailsCount }} email subfolders, each with a specific template. Each email folder contains the following files:
|
|
||||||
* Compiled HTML files for light and dark themes. Read more about their usage in the [Compiled HTML](/emails/introduction/compiled-html) section.
|
|
||||||
* Source HTML files for light and dark themes. Find more information in the [Source HTML](/emails/introduction/source-html) section.
|
|
||||||
* Screenshot images for desktop and mobile views.
|
|
||||||
* Assets folder with images used in the email template and the CSS file with styles.
|
|
||||||
|
|
||||||
### 2. Images: `images/`
|
|
||||||
It contains 4 subfolders with images used across the different email templates:
|
|
||||||
* `chart-donuts/`: Images of donut charts with different fills.
|
|
||||||
* `icons/`: [Tabler Icons](/icons) used in the email templates, in PNG version.
|
|
||||||
* `illustrations/`: PNG versions of [Tabler Illustrations](/illustrations) for light and dark themes.
|
|
||||||
* `overlays/`: Overlay images used in the email templates.
|
|
||||||
|
|
||||||
### 3. License: `license.txt`
|
|
||||||
This file contains the license information for the Tabler Emails package.
|
|
||||||
|
|
||||||
### 4. Readme: `readme.html`
|
|
||||||
This file contains the main information about the Tabler Emails package, including a brief description and instructions on how to use it.
|
|
||||||
|
|
||||||
Do you like our templates? **Find out more and purchase on [our website]({{ site.homepage }}/emails)**.
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
---
|
|
||||||
title: Introduction
|
|
||||||
seoTitle: Introduction to Tabler Emails
|
|
||||||
description: Base information about Tabler Emails package.
|
|
||||||
summary: Tabler Emails is a set of 80 eye-catching, customizable HTML templates. They are compatible with over 90 email clients and devices.
|
|
||||||
seoDescription: Tabler Emails is a collection of 80 premium, customizable HTML templates. They are compatible with over 90 email clients and devices.
|
|
||||||
---
|
|
||||||
|
|
||||||
|
|
||||||
@@ -1,26 +0,0 @@
|
|||||||
---
|
|
||||||
title: Source templates
|
|
||||||
order: 3
|
|
||||||
seoTitle: Tabler Emails - How to use the source HTML email templates
|
|
||||||
description: Learn how to use the source HTML email templates from the Tabler Emails package.
|
|
||||||
summary: The source HTML files from the Tabler Emails package need a bit more work than the compiled ones. Learn how to use them.
|
|
||||||
seoDescription: The source HTML files from the Tabler Emails package need a bit more work than the compiled ones. Learn how to use them.
|
|
||||||
---
|
|
||||||
|
|
||||||
## Source version of the template
|
|
||||||
|
|
||||||
If you want to make more advanced changes to the email template, you can use the source HTML files - `source.html` combined with the `theme.css` file. They are ready to use, but you need a basic knowledge of HTML and CSS to modify them.
|
|
||||||
|
|
||||||
## How to modify the source HTML files
|
|
||||||
|
|
||||||
1. Open the `source.html` file in your favorite code editor.
|
|
||||||
2. Open the `theme.css` file from the `assets/`* directory in the same editor.
|
|
||||||
3. Change all the content and styles as needed.
|
|
||||||
4. Use a selected tool to inline the CSS styles into the HTML file. There are a lot of options, such as:
|
|
||||||
* Online tools like [Juice](https://automattic.github.io/juice/) or [Mailchimp CSS Inliner Tool](https://templates.mailchimp.com/resources/inline-css/).
|
|
||||||
* NPM tools like [juice](https://www.npmjs.com/package/juice) or [inline-css](https://www.npmjs.com/package/inline-css).
|
|
||||||
5. Save the output HTML file.
|
|
||||||
|
|
||||||
## How to use the source HTML files
|
|
||||||
|
|
||||||
To use the modified HTML template send the output file with the `assets/` folder to your email marketing tool.
|
|
||||||
File diff suppressed because it is too large
Load Diff
@@ -1,17 +0,0 @@
|
|||||||
---
|
|
||||||
title: Preview
|
|
||||||
summary: "Tabler Illustrations offers 80 illustrations in two themes: light and dark. You can use them in your projects to enhance the visual appeal and convey messages effectively."
|
|
||||||
---
|
|
||||||
|
|
||||||
Look at full list of illustrations below and see how they look. Find out more and purchase Tabler Illustrations at [our website]({{ site.homepage }}/illustrations).
|
|
||||||
|
|
||||||
{% assign all-illustrations = illustrations | sort %}
|
|
||||||
<div class="row g-2 gy-6">
|
|
||||||
{% for illustration in all-illustrations %}
|
|
||||||
<div class="col-6 col-md-4 col-lg-3 text-center">
|
|
||||||
<img src="/static/illustrations/light/{{ illustration }}.png" alt="{{ illustration }}" class="hide-theme-dark" />
|
|
||||||
<img src="/static/illustrations/dark/{{ illustration }}.png" alt="{{ illustration }}" class="hide-theme-light" />
|
|
||||||
<code>{{ illustration }}</code>
|
|
||||||
</div>
|
|
||||||
{% endfor %}
|
|
||||||
</div>
|
|
||||||
@@ -1,19 +0,0 @@
|
|||||||
---
|
|
||||||
title: Welcome to Tabler Documentation
|
|
||||||
summary: Tabler Docs provides a comprehensive guide to help you get started with the Tabler ecosystem, including its UI components, plugins, and icons. Explore detailed documentation to understand and leverage the full potential of Tabler in your projects.
|
|
||||||
---
|
|
||||||
|
|
||||||
<img src="/img/tabler.png" alt="Tabler" class="mb-4 hide-theme-dark border-0" width="816" height="620" />
|
|
||||||
<img src="/img/tabler-dark.png" alt="Tabler" class="mb-4 hide-theme-light border-0" width="816" height="620" />
|
|
||||||
|
|
||||||
Find all the guides and resources you need to develop with Tabler and our other tools. Explore our UI components, icons, illustrations, and email templates to enhance your web development experience. Our tools are designed to be easy to use, customizable, and fully responsive, ensuring that your projects look great on any device.
|
|
||||||
|
|
||||||
<div class="mt-6 pt-6">
|
|
||||||
<div class="row row-deck row-cards">
|
|
||||||
{% include "docs/docs-card.html" title="UI Components" href="/ui" icon="paint" description="Free and open source web application UI kit based on Bootstrap" %}
|
|
||||||
{% include "docs/docs-card.html" title="Plugins" href="/plugins" icon="plug" description="Free and open source plugins for Tabler UI components" %}
|
|
||||||
{% include "docs/docs-card.html" title="Icons" href="/icons" icon="ghost" description="Pixel-perfect icons for web design and development" %}
|
|
||||||
{% include "docs/docs-card.html" title="Illustrations" href="/illustrations" icon="brand-figma" description="Customizable SVG illustrations for your web project" %}
|
|
||||||
{% include "docs/docs-card.html" title="Email Templates" href="/emails" icon="mail" description="Responsive email templates ready to use in your marketing campaigns" %}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
@@ -1,30 +0,0 @@
|
|||||||
---
|
|
||||||
title: Colors
|
|
||||||
summary: The choice of colors for a website or app interface has a big influence on how users interact with the product and what decisions they make. Harmonious colors can contribute to a nice first impression and encourage users to engage with your product, so it's a very important aspect of a successful design, which needs to be well thought out.
|
|
||||||
bootstrapLink: utilities/colors/
|
|
||||||
description: Impact of colors on user interface design.
|
|
||||||
---
|
|
||||||
|
|
||||||
## Base colors
|
|
||||||
|
|
||||||
Choose one of the available colors from the basic color palette and make your design attractive for users. You can use the colors to customize the design of components, indicate different states or suggest actions you want users to take.
|
|
||||||
|
|
||||||
{% include "docs/colors.html" colors=site.colors %}
|
|
||||||
|
|
||||||
## Light colors
|
|
||||||
|
|
||||||
All available colors can come in pastel shades, which are perfect for more subtle designs and can be easily combined with the basic palette to create eye-catching designs.
|
|
||||||
|
|
||||||
{% include "docs/colors.html" colors=site.lightColors %}
|
|
||||||
|
|
||||||
## Gray palette
|
|
||||||
|
|
||||||
The gray palette is a great choice for creating a neutral background for your design. It can be used to create a clean and professional look, and can be combined with other colors to create a harmonious design.
|
|
||||||
|
|
||||||
{% include "docs/colors.html" colors=site.grayColors %}
|
|
||||||
|
|
||||||
## Social colors
|
|
||||||
|
|
||||||
Use the colors of popular social networks to create a recognizable design and make it easier for users to interact with your product.
|
|
||||||
|
|
||||||
{% include "docs/colors.html" colors=site.socialColors %}
|
|
||||||
@@ -1,184 +0,0 @@
|
|||||||
---
|
|
||||||
title: Avatars
|
|
||||||
summary: Avatars help customize various elements of a user interface and make the product experience more personalized. They are often used in communication apps, collaboration tools and social media.
|
|
||||||
description: Personalize UI with user avatars.
|
|
||||||
---
|
|
||||||
|
|
||||||
## Default markup
|
|
||||||
|
|
||||||
Use the `avatar` class to add an avatar to your interface design for greater customization.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<span class="avatar" style="background-image: url(/static/avatars/002f.jpg)"></span>
|
|
||||||
<span class="avatar">JL</span>
|
|
||||||
<span class="avatar" style="background-image: url(/static/avatars/004f.jpg)"></span>
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Avatar image
|
|
||||||
|
|
||||||
Set an image as the background to make users easy to indentify and create a personalized experience.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<span class="avatar" style="background-image: url(/static/avatars/016f.jpg)"></span>
|
|
||||||
<span class="avatar" style="background-image: url(/static/avatars/022m.jpg)"></span>
|
|
||||||
<span class="avatar" style="background-image: url(/static/avatars/036m.jpg)"></span>
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Initials
|
|
||||||
|
|
||||||
You can also use initials instead of pictures.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<span class="avatar">AB</span>
|
|
||||||
<span class="avatar">CD</span>
|
|
||||||
<span class="avatar">EF</span>
|
|
||||||
<span class="avatar">GH</span>
|
|
||||||
<span class="avatar">IJ</span>
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Avatar icons
|
|
||||||
|
|
||||||
Besides pictures and initials, you can also use icons to make the avatars more universal.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<span class="avatar">
|
|
||||||
{% include "ui/icon.html" icon="user" %}
|
|
||||||
</span>
|
|
||||||
<span class="avatar">
|
|
||||||
{% include "ui/icon.html" icon="plus" %}
|
|
||||||
</span>
|
|
||||||
<span class="avatar">
|
|
||||||
{% include "ui/icon.html" icon="settings" %}
|
|
||||||
</span>
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Avatar initials color
|
|
||||||
|
|
||||||
Customize the color of the avatars' background. See the [full list of available colors](/ui/base/colors) for more details.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<span class="avatar bg-green-lt">AB</span>
|
|
||||||
<span class="avatar bg-red-lt">CD</span>
|
|
||||||
<span class="avatar bg-yellow-lt">EF</span>
|
|
||||||
<span class="avatar bg-primary-lt">GH</span>
|
|
||||||
<span class="avatar bg-purple-lt">IJ</span>
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Avatar size
|
|
||||||
|
|
||||||
Using Bootstrap’s typical naming structure, you can create a standard avatar or scale it up or down to different sizes based on what you need.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<span class="avatar avatar-xl" style="background-image: url(/static/avatars/000m.jpg)"></span>
|
|
||||||
<span class="avatar avatar-lg" style="background-image: url(/static/avatars/000m.jpg)"></span>
|
|
||||||
<span class="avatar" style="background-image: url(/static/avatars/000m.jpg)"></span>
|
|
||||||
<span class="avatar avatar-sm" style="background-image: url(/static/avatars/000m.jpg)"></span>
|
|
||||||
<span class="avatar avatar-xs" style="background-image: url(/static/avatars/000m.jpg)"></span>
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Avatar status
|
|
||||||
|
|
||||||
Add a status indicator to your avatar to show, for instance, if a user is online or offline or indicate the number of messages they have received.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<span class="avatar" style="background-image: url(/static/avatars/018m.jpg)"></span>
|
|
||||||
<span class="avatar" style="background-image: url(/static/avatars/015m.jpg)">
|
|
||||||
<span class="badge bg-danger"></span>
|
|
||||||
</span>
|
|
||||||
<span class="avatar" style="background-image: url(/static/avatars/022m.jpg)">
|
|
||||||
<span class="badge bg-success"></span>
|
|
||||||
</span>
|
|
||||||
<span class="avatar"> <span class="badge bg-warning"></span>SA </span>
|
|
||||||
<span class="avatar" style="background-image: url(/static/avatars/022m.jpg)">
|
|
||||||
<span class="badge bg-info"></span>
|
|
||||||
</span>
|
|
||||||
<span class="avatar" style="background-image: url(/static/avatars/048m.jpg)">
|
|
||||||
<span class="badge bg-gray">5</span>
|
|
||||||
</span>
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Avatar shape
|
|
||||||
|
|
||||||
Change the shape of an avatar with the default Bootstrap image classes. You can make them round or square and change their border radius.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<span class="avatar" style="background-image: url(/static/avatars/019m.jpg)"></span>
|
|
||||||
<span class="avatar rounded" style="background-image: url(/static/avatars/039f.jpg)"></span>
|
|
||||||
<span class="avatar rounded-circle">AA</span>
|
|
||||||
<span class="avatar rounded-0" style="background-image: url(/static/avatars/043f.jpg)"></span>
|
|
||||||
<span class="avatar rounded-3" style="background-image: url(/static/avatars/044f.jpg)"></span>
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Avatars list
|
|
||||||
|
|
||||||
Create a list of avatars within one parent container.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<div class="avatar-list">
|
|
||||||
<span class="avatar rounded" style="background-image: url(/static/avatars/031f.jpg)"></span>
|
|
||||||
<span class="avatar rounded">JL</span>
|
|
||||||
<span class="avatar rounded" style="background-image: url(/static/avatars/033f.jpg)"></span>
|
|
||||||
<span class="avatar rounded" style="background-image: url(/static/avatars/017m.jpg)"></span>
|
|
||||||
<span class="avatar rounded" style="background-image: url(/static/avatars/024m.jpg)"></span>
|
|
||||||
</div>
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Stacked list
|
|
||||||
|
|
||||||
Make the list stack once a certain number of avatars is reached to make it look clear and display well regardless of the screen size.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<div class="avatar-list avatar-list-stacked">
|
|
||||||
<span class="avatar">EB</span>
|
|
||||||
<span class="avatar" style="background-image: url(/static/avatars/026m.jpg)"></span>
|
|
||||||
<span class="avatar" style="background-image: url(/static/avatars/016f.jpg)"></span>
|
|
||||||
<span class="avatar" style="background-image: url(/static/avatars/028m.jpg)"></span>
|
|
||||||
<span class="avatar" style="background-image: url(/static/avatars/030m.jpg)"></span>
|
|
||||||
<span class="avatar">+8</span>
|
|
||||||
</div>
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<div class="avatar-list avatar-list-stacked">
|
|
||||||
<span
|
|
||||||
class="avatar avatar-sm rounded-circle"
|
|
||||||
style="background-image: url(/static/avatars/035m.jpg)"
|
|
||||||
></span>
|
|
||||||
<span
|
|
||||||
class="avatar avatar-sm rounded-circle"
|
|
||||||
style="background-image: url(/static/avatars/027f.jpg)"
|
|
||||||
></span>
|
|
||||||
<span
|
|
||||||
class="avatar avatar-sm rounded-circle"
|
|
||||||
style="background-image: url(/static/avatars/036f.jpg)"
|
|
||||||
></span>
|
|
||||||
<span class="avatar avatar-sm rounded-circle">SA</span>
|
|
||||||
<span
|
|
||||||
class="avatar avatar-sm rounded-circle"
|
|
||||||
style="background-image: url(/static/avatars/034f.jpg)"
|
|
||||||
></span>
|
|
||||||
<span
|
|
||||||
class="avatar avatar-sm rounded-circle"
|
|
||||||
style="background-image: url(/static/avatars/043f.jpg)"
|
|
||||||
></span>
|
|
||||||
<span
|
|
||||||
class="avatar avatar-sm rounded-circle"
|
|
||||||
style="background-image: url(/static/avatars/039f.jpg)"
|
|
||||||
></span>
|
|
||||||
<span
|
|
||||||
class="avatar avatar-sm rounded-circle"
|
|
||||||
style="background-image: url(/static/avatars/020m.jpg)"
|
|
||||||
></span>
|
|
||||||
</div>
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
@@ -1,185 +0,0 @@
|
|||||||
---
|
|
||||||
title: Badges
|
|
||||||
summary: Badges are small count and labeling components, which are used to add extra information to an interface element. You can use them to draw users' attention to a new element, notify about unread messages or provide any kind of additional info.
|
|
||||||
description: Add extra information with badges.
|
|
||||||
bootstrapLink: components/badge/
|
|
||||||
---
|
|
||||||
|
|
||||||
## Default markup
|
|
||||||
|
|
||||||
The default badges are square and come in the basic set of colors.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<div class="badges-list">
|
|
||||||
{% for color in site.colors -%}
|
|
||||||
{% include "ui/badge.html" color=color[0] text=color[1].title %}
|
|
||||||
{%- endfor -%}
|
|
||||||
</div>
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Headings
|
|
||||||
|
|
||||||
Badges can be used in headings to draw attention to new or important information. You can use them in any heading level, from `<h1>` to `<h6>`. The example below shows how to use badges in headings.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<h1>
|
|
||||||
Example heading
|
|
||||||
{% include "ui/badge.html" text="New" -%}
|
|
||||||
</h1>
|
|
||||||
<h2>
|
|
||||||
Example heading
|
|
||||||
{% include "ui/badge.html" text="New" -%}
|
|
||||||
</h2>
|
|
||||||
<h3>
|
|
||||||
Example heading
|
|
||||||
{% include "ui/badge.html" text="New" -%}
|
|
||||||
</h3>
|
|
||||||
<h4>
|
|
||||||
Example heading
|
|
||||||
{% include "ui/badge.html" text="New" -%}
|
|
||||||
</h4>
|
|
||||||
<h5>
|
|
||||||
Example heading
|
|
||||||
{% include "ui/badge.html" text="New" -%}
|
|
||||||
</h5>
|
|
||||||
<h6>
|
|
||||||
Example heading
|
|
||||||
{% include "ui/badge.html" text="New" -%}
|
|
||||||
</h6>
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html %}
|
|
||||||
|
|
||||||
## Light versions of badges
|
|
||||||
|
|
||||||
You can use the `-lt` classes to create a light version of the badge. This is useful for creating a more subtle look.
|
|
||||||
|
|
||||||
For example you can use the `bg-blue-lt` class to create a light blue badge. If you add the `text-blue-lt-fg` class, the text will be blue as well.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
{%- for color in site.colors -%}
|
|
||||||
{% include "ui/badge.html" color=color[0] text=color[1].title light %}
|
|
||||||
{%- endfor -%}
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Pill badges
|
|
||||||
|
|
||||||
Use the `.badge-pill` class if you want to create a badge with rounded corners. Its width will adjust to the label text.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
{%- for color in site.colors -%}
|
|
||||||
{% include "ui/badge.html" color=color[0] text=color[1].title class="badge-pill" %}
|
|
||||||
{%- endfor -%}
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
You can use it to create a pill with numbers, for example, to show the number of unread messages. The badge will adjust its width to the number of digits.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
{%- for color in site.colors -%}
|
|
||||||
{% include "ui/badge.html" color=color[0] text=forloop.index class="badge-pill" %}
|
|
||||||
{%- endfor -%}
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Badges with icons
|
|
||||||
|
|
||||||
You can use icons in badges to make them more visually appealing. The example below demonstrates how to use icons in badges.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
{% include "ui/badge.html" text="Star" icon="star" -%}
|
|
||||||
{% include "ui/badge.html" text="Heart" icon="heart" -%}
|
|
||||||
{% include "ui/badge.html" text="Check" icon="check" -%}
|
|
||||||
{% include "ui/badge.html" text="X" icon="x" -%}
|
|
||||||
{% include "ui/badge.html" text="Plus" icon="plus" -%}
|
|
||||||
{% include "ui/badge.html" text="Minus" icon="minus" -%}
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
You can also use an icon on the right side of the badge. The example below demonstrates how to use icons on the right side of badges.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
{% include "ui/badge.html" text="Star" icon-end="arrow-right" -%}
|
|
||||||
{% include "ui/badge.html" text="Heart" icon-end="arrow-right" -%}
|
|
||||||
{% include "ui/badge.html" text="Check" icon-end="arrow-right" -%}
|
|
||||||
{% include "ui/badge.html" text="X" icon-end="arrow-right" -%}
|
|
||||||
{% include "ui/badge.html" text="Plus" icon-end="arrow-right" -%}
|
|
||||||
{% include "ui/badge.html" text="Minus" icon-end="arrow-right" -%}
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Links
|
|
||||||
|
|
||||||
Place the badge within an `<a>` element if you want it to perform the function of a link and make it clickable.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<a href="#" class="badge bg-blue-lt">Blue</a>
|
|
||||||
<a href="#" class="badge bg-azure-lt">Azure</a>
|
|
||||||
<a href="#" class="badge bg-indigo-lt">Indigo</a>
|
|
||||||
<a href="#" class="badge bg-purple-lt">Purple</a>
|
|
||||||
<a href="#" class="badge bg-pink-lt">Pink</a>
|
|
||||||
<a href="#" class="badge bg-red-lt">Red</a>
|
|
||||||
<a href="#" class="badge bg-orange-lt">Orange</a>
|
|
||||||
<a href="#" class="badge bg-yellow-lt">Yellow</a>
|
|
||||||
<a href="#" class="badge bg-lime-lt">Lime</a>
|
|
||||||
<a href="#" class="badge bg-green-lt">Green</a>
|
|
||||||
<a href="#" class="badge bg-teal-lt">Teal</a>
|
|
||||||
<a href="#" class="badge bg-cyan-lt">Cyan</a>
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Button with badge
|
|
||||||
|
|
||||||
Badges can be used as parts of links or buttons to provide, for example, a counter. Use the `.badge-notification` class to create a notification badge. This class will position the badge in the top right corner of the button.
|
|
||||||
|
|
||||||
If you don't provide text for the badge, you end up with a small dot. This is useful for creating a simple notification button.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<button type="button" class="btn">
|
|
||||||
Notifications {% include "ui/badge.html" text="2" color="red" class="ms-2" -%}
|
|
||||||
</button>
|
|
||||||
<button type="button" class="btn">
|
|
||||||
Inbox {% include "ui/badge.html" text="4" color="red" class="badge-notification" -%}
|
|
||||||
</button>
|
|
||||||
<button type="button" class="btn">
|
|
||||||
Profile {% include "ui/badge.html" text="" color="red" class="badge-notification" -%}
|
|
||||||
</button>
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Animated badges
|
|
||||||
|
|
||||||
You can use the `.badge-blink` class to create a blinking effect. This class will add a CSS animation to the badge, so it will blink to draw attention.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<button type="button" class="btn">
|
|
||||||
Profile {% include "ui/badge.html" text="" color="red" class="badge-notification badge-blink" -%}
|
|
||||||
</button>
|
|
||||||
{% endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Size Options
|
|
||||||
|
|
||||||
Use `.badge-sm` or `.badge-lg` to change badge size according to your needs. The default size is `.badge` and it is used in the examples above.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<div>
|
|
||||||
{% include "ui/badge.html" color="primary" scale="sm" text="New" class="badge-sm" -%}
|
|
||||||
{% include "ui/badge.html" color="primary" scale="sm" text="1" class="badge-pill" -%}
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
{% include "ui/badge.html" color="primary" text="New" class="badge-sm" -%}
|
|
||||||
{% include "ui/badge.html" color="primary" text="1" class="badge-pill" -%}
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
{% include "ui/badge.html" color="primary" scale="lg" text="New" class="badge-sm" -%}
|
|
||||||
{% include "ui/badge.html" color="primary" scale="lg" text="1" class="badge-pill" -%}
|
|
||||||
</div>
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered vertical %}
|
|
||||||
|
|
||||||
|
|
||||||
## More examples
|
|
||||||
|
|
||||||
If you want to see more examples of badges, you can check out the [Bootstrap documentation](https://getbootstrap.com/docs/5.3/components/badge/) for badges. You can also find more examples in the Tabler [Badges](https://preview.tabler.io/badges.html) preview.
|
|
||||||
@@ -1,76 +0,0 @@
|
|||||||
---
|
|
||||||
title: Breadcrumb
|
|
||||||
summary: Breadcrumbs are used to show the current website or app location and reduce the number of actions users have to take. Thanks to breadcrumbs, they can easily navigate within the website hierarchy and better understand its structure.
|
|
||||||
bootstrapLink: components/breadcrumb/
|
|
||||||
description: Navigation aid for better structure.
|
|
||||||
---
|
|
||||||
|
|
||||||
## Default markup
|
|
||||||
|
|
||||||
Use the `breadcrumb` class to add a breadcrumb to your interface design for better navigation. The `active` modifier in a `li` tag will help you indicate the current page location and facilitate navigation within your website or app.
|
|
||||||
|
|
||||||
Look at the example below to see how breadcrumbs work in practice.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
{% include "ui/breadcrumb.html" pages="Home,Library,Data" %}
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Different separators
|
|
||||||
|
|
||||||
You can use different breadcrumb styles to match your website or app design. Choose between `breadcrumb-dots`, `breadcrumb-arrows`, and `breadcrumb-bullets` to create a unique look.
|
|
||||||
|
|
||||||
This example shows how to use different breadcrumb styles.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
{% include "ui/breadcrumb.html" pages="Home,Library,Data" separator="dots" %}
|
|
||||||
{% include "ui/breadcrumb.html" pages="Home,Library,Data" separator="arrows" %}
|
|
||||||
{% include "ui/breadcrumb.html" pages="Home,Library,Data" separator="bullets" %}
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html vertical separated centered %}
|
|
||||||
|
|
||||||
## With icon
|
|
||||||
|
|
||||||
You can use icons in breadcrumbs to make them more visually appealing. The example below demonstrates how to use icons in breadcrumbs.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
{% include "ui/breadcrumb.html" pages="Home,Library,Data" home-icon %}
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html vertical separated %}
|
|
||||||
|
|
||||||
## Muted breadcrumbs
|
|
||||||
|
|
||||||
You can use the `breadcrumb-muted` class to create a muted breadcrumb style. This style is perfect for breadcrumbs that are not the main focus of your website or app.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
{% include "ui/breadcrumb.html" pages="Home,Library,Data" class="breadcrumb-muted" %}
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html %}
|
|
||||||
|
|
||||||
## Breadcrumb in headers
|
|
||||||
|
|
||||||
You can use breadcrumbs in headers to show the current page location and provide a better navigation experience. The example below demonstrates how to use breadcrumbs in headers.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<div class="page-header">
|
|
||||||
<div class="row align-items-center mw-100">
|
|
||||||
<div class="col">
|
|
||||||
{% include "ui/breadcrumb.html" pages="Home,Library,Articles" -%}
|
|
||||||
<h2 class="page-title">
|
|
||||||
<span class="text-truncate">How to Build a Modern Dashboard with Tabler</span>
|
|
||||||
</h2>
|
|
||||||
</div>
|
|
||||||
<div class="col-auto">
|
|
||||||
<div class="btn-list">
|
|
||||||
<a href="#" class="btn d-none d-md-inline-flex">
|
|
||||||
{% include "ui/icon.html" icon="edit" %}
|
|
||||||
Edit
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-primary">Publish</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
{%- endcapture %}
|
|
||||||
{% include "docs/example.html" html=html centered vertical %}
|
|
||||||
|
|
||||||
@@ -1,679 +0,0 @@
|
|||||||
---
|
|
||||||
title: Buttons
|
|
||||||
summary: Use button styles that best suit your designs and encourage users to take the desired actions. You can customize the button's properties to improve the user experience of your website or system, changing the size, shape, color and many more.
|
|
||||||
bootstrapLink: components/buttons/
|
|
||||||
description: Customizable buttons for user actions.
|
|
||||||
---
|
|
||||||
|
|
||||||
## Button tag
|
|
||||||
|
|
||||||
As one of the most common elements of UI design, buttons have a very important function of engaging users within your website or app and guiding them in their actions. Use the `.btn` classes with the `<button>` element and add additional styling that will make your buttons serve their purpose and draw users' attention.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<a href="#" class="btn" role="button">Link</a>
|
|
||||||
<button class="btn">Button</button>
|
|
||||||
<input type="button" class="btn" value="Input" />
|
|
||||||
<input type="submit" class="btn" value="Submit" />
|
|
||||||
<input type="reset" class="btn" value="Reset" />
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Default button
|
|
||||||
|
|
||||||
The standard button creates a white background and subtle hover animation. It's meant to look and behave as an interactive element of your page.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<a href="#" class="btn" role="button">Link</a>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Button variations
|
|
||||||
|
|
||||||
Use the button classes that correspond to the function of your button. The big range of available colors will help you show your button's purpose and make it easy to spot.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<a href="#" class="btn btn-primary">Primary</a>
|
|
||||||
<a href="#" class="btn btn-secondary">Secondary</a>
|
|
||||||
<a href="#" class="btn btn-success">Success</a>
|
|
||||||
<a href="#" class="btn btn-warning">Warning</a>
|
|
||||||
<a href="#" class="btn btn-danger">Danger</a>
|
|
||||||
<a href="#" class="btn btn-info">Info</a>
|
|
||||||
<a href="#" class="btn btn-dark">Dark</a>
|
|
||||||
<a href="#" class="btn btn-light">Light</a>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html separated centered %}
|
|
||||||
|
|
||||||
## Disabled buttons
|
|
||||||
|
|
||||||
Make buttons look inactive to show that an action is possible once the user meets certain criteria, such as completing the required fields to submit a form.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<a href="#" class="btn btn-primary disabled">Primary</a>
|
|
||||||
<a href="#" class="btn btn-secondary disabled">Secondary</a>
|
|
||||||
<a href="#" class="btn btn-success disabled">Success</a>
|
|
||||||
<a href="#" class="btn btn-warning disabled">Warning</a>
|
|
||||||
<a href="#" class="btn btn-danger disabled">Danger</a>
|
|
||||||
<a href="#" class="btn btn-info disabled">Info</a>
|
|
||||||
<a href="#" class="btn btn-dark disabled">Dark</a>
|
|
||||||
<a href="#" class="btn btn-light disabled">Light</a>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html separated centered %}
|
|
||||||
|
|
||||||
## Color variations
|
|
||||||
|
|
||||||
Choose the right color for your button to make it go well with your design and draw users' attention. Button colors can have a big influence on users' decisions, which is why it's important to choose them based on the intended purpose.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<a href="#" class="btn btn-blue">Blue</a>
|
|
||||||
<a href="#" class="btn btn-azure">Azure</a>
|
|
||||||
<a href="#" class="btn btn-indigo">Indigo</a>
|
|
||||||
<a href="#" class="btn btn-purple">Purple</a>
|
|
||||||
<a href="#" class="btn btn-pink">Pink</a>
|
|
||||||
<a href="#" class="btn btn-red">Red</a>
|
|
||||||
<a href="#" class="btn btn-orange">Orange</a>
|
|
||||||
<a href="#" class="btn btn-yellow">Yellow</a>
|
|
||||||
<a href="#" class="btn btn-lime">Lime</a>
|
|
||||||
<a href="#" class="btn btn-green">Green</a>
|
|
||||||
<a href="#" class="btn btn-teal">Teal</a>
|
|
||||||
<a href="#" class="btn btn-cyan">Cyan</a>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html separated centered %}
|
|
||||||
|
|
||||||
## Ghost buttons
|
|
||||||
|
|
||||||
Use the `.btn-ghost-*` class to make your button look simple yet aesthetically appealing. Ghost buttons help focus users' attention on the website's primary design, encouraging them to take action at the same time.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<a href="#" class="btn btn-ghost-primary">Primary</a>
|
|
||||||
<a href="#" class="btn btn-ghost-secondary">Secondary</a>
|
|
||||||
<a href="#" class="btn btn-ghost-success">Success</a>
|
|
||||||
<a href="#" class="btn btn-ghost-warning">Warning</a>
|
|
||||||
<a href="#" class="btn btn-ghost-danger">Danger</a>
|
|
||||||
<a href="#" class="btn btn-ghost-info">Info</a>
|
|
||||||
<a href="#" class="btn btn-ghost-dark">Dark</a>
|
|
||||||
<div class="p-2 bg-dark">
|
|
||||||
<a href="#" class="btn btn-ghost-light">Light</a>
|
|
||||||
</div>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html separated vertical %}
|
|
||||||
|
|
||||||
## Square buttons
|
|
||||||
|
|
||||||
Use the `.btn-square` class to remove the border radius, if you want the corners of your button to be square rather than rounded.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<a href="#" class="btn btn-square">Square button</a>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Pill buttons
|
|
||||||
|
|
||||||
Add the `.btn-pill` class to your button to make it rounded and give it a modern and attractive look.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<a href="#" class="btn btn-pill">Pill button</a>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Outline buttons
|
|
||||||
|
|
||||||
Replace the default modifier class with the `.btn-outline-*` class, if you want to remove the color and the background of your button and give it a more subtle look. Outline buttons are perfect to use as secondary buttons, as they don't distract users from the main action.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<a href="#" class="btn btn-outline-primary">Primary</a>
|
|
||||||
<a href="#" class="btn btn-outline-secondary">Secondary</a>
|
|
||||||
<a href="#" class="btn btn-outline-success">Success</a>
|
|
||||||
<a href="#" class="btn btn-outline-warning">Warning</a>
|
|
||||||
<a href="#" class="btn btn-outline-danger">Danger</a>
|
|
||||||
<a href="#" class="btn btn-outline-info">Info</a>
|
|
||||||
<a href="#" class="btn btn-outline-dark">Dark</a>
|
|
||||||
<a href="#" class="btn btn-outline-light">Light</a>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Button size
|
|
||||||
|
|
||||||
Add `.btn-lg` or `.btn-sm` to change the size of your button and differentiate those which should have primary focus from those of secondary importance. Adapt the button size to your design and encourage users to take actions.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<button type="button" class="btn btn-primary btn-lg">Large button</button>
|
|
||||||
<button type="button" class="btn btn-lg">Large button</button>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<button type="button" class="btn btn-primary btn-sm">Small button</button>
|
|
||||||
<button type="button" class="btn btn-sm">Small button</button>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Buttons with icons
|
|
||||||
|
|
||||||
Label your button with text and add an icon to communicate the action and make it easy to identify for users. Icons are easily recognized and improve the aesthetics of your button design, giving it a modern and attractive look.
|
|
||||||
|
|
||||||
See all icons at [tabler.io/icons]({{ site.icons.link }}).
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<button type="button" class="btn">
|
|
||||||
{% include "ui/icon.html" icon="upload" -%}
|
|
||||||
Upload
|
|
||||||
</button>
|
|
||||||
<button type="button" class="btn btn-warning">
|
|
||||||
{% include "ui/icon.html" icon="heart" -%}
|
|
||||||
I like
|
|
||||||
</button>
|
|
||||||
<button type="button" class="btn btn-success">
|
|
||||||
{% include "ui/icon.html" icon="check" -%}
|
|
||||||
I agree
|
|
||||||
</button>
|
|
||||||
<button type="button" class="btn btn-primary">
|
|
||||||
{% include "ui/icon.html" icon="plus" -%}
|
|
||||||
More
|
|
||||||
</button>
|
|
||||||
<button type="button" class="btn btn-danger">
|
|
||||||
{% include "ui/icon.html" icon="link" -%}
|
|
||||||
Link
|
|
||||||
</button>
|
|
||||||
<button type="button" class="btn btn-info">
|
|
||||||
{% include "ui/icon.html" icon="message" -%}
|
|
||||||
Comment
|
|
||||||
</button>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Social buttons
|
|
||||||
|
|
||||||
You can use the icons of popular social networking sites, which users are familiar with. Thanks to buttons with social media icons users can share content or follow a website with just one click, without leaving the website.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<a href="#" class="btn btn-facebook">
|
|
||||||
{%- include "ui/icon.html" icon="brand-facebook" -%}
|
|
||||||
Facebook
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-twitter">
|
|
||||||
{%- include "ui/icon.html" icon="brand-twitter" -%}
|
|
||||||
Twitter
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-google">
|
|
||||||
{%- include "ui/icon.html" icon="brand-google" -%}
|
|
||||||
Google
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-youtube">
|
|
||||||
{%- include "ui/icon.html" icon="brand-youtube" -%}
|
|
||||||
Youtube
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-vimeo">
|
|
||||||
{%- include "ui/icon.html" icon="brand-vimeo" -%}
|
|
||||||
Vimeo
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-dribbble">
|
|
||||||
{%- include "ui/icon.html" icon="brand-dribbble" -%}
|
|
||||||
Dribbble
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-github">
|
|
||||||
{%- include "ui/icon.html" icon="brand-github" -%}
|
|
||||||
Github
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-instagram">
|
|
||||||
{%- include "ui/icon.html" icon="brand-instagram" -%}
|
|
||||||
Instagram
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-pinterest">
|
|
||||||
{%- include "ui/icon.html" icon="brand-pinterest" -%}
|
|
||||||
Pinterest
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-vk">
|
|
||||||
{%- include "ui/icon.html" icon="brand-vk" -%}
|
|
||||||
VK
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-rss">
|
|
||||||
{%- include "ui/icon.html" icon="brand-rss" -%}
|
|
||||||
RSS
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-flickr">
|
|
||||||
{%- include "ui/icon.html" icon="brand-flickr" -%}
|
|
||||||
Flickr
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-bitbucket">
|
|
||||||
{%- include "ui/icon.html" icon="brand-bitbucket" -%}
|
|
||||||
Bitbucket
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-tabler">
|
|
||||||
{%- include "ui/icon.html" icon="brand-tabler" -%}
|
|
||||||
Tabler
|
|
||||||
</a>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html separated centered hide-code %}
|
|
||||||
|
|
||||||
```html
|
|
||||||
<a href="#" class="btn btn-facebook">
|
|
||||||
<svg>...</svg>
|
|
||||||
Facebook
|
|
||||||
</a>
|
|
||||||
```
|
|
||||||
|
|
||||||
You can also add an icon without the name of a social networking site, if you want to display more buttons in a small space.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<a href="#" class="btn btn-facebook btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="brand-facebook" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-x btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="brand-x" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-google btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="brand-google" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-youtube btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="brand-youtube" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-vimeo btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="brand-vimeo" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-dribbble btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="brand-dribbble" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-github btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="brand-github" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-instagram btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="brand-instagram" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-pinterest btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="brand-pinterest" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-vk btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="brand-vk" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-rss btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="rss" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-flickr btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="brand-flickr" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-bitbucket btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="brand-bitbucket" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-tabler btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="brand-tabler" -%}
|
|
||||||
</a>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html separated vertical hide-code %}
|
|
||||||
|
|
||||||
```html
|
|
||||||
<a href="#" class="btn btn-facebook btn-icon" aria-label="Button">
|
|
||||||
<svg>...</svg>
|
|
||||||
</a>
|
|
||||||
```
|
|
||||||
|
|
||||||
## Icon buttons
|
|
||||||
|
|
||||||
Add the `.btn-icon` class to remove unnecessary padding from your button and use an icon without any additional label. Thanks to that, you can save space and make the action easy to recognize for international users.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<a href="#" class="btn btn-primary btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="activity" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-github btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="brand-github" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-success btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="bell" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-warning btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="star" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-danger btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="trash" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-purple btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="chart-bar" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-icon" aria-label="Button">
|
|
||||||
{%- include "ui/icon.html" icon="git-merge" -%}
|
|
||||||
</a>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html separated centered hide-code %}
|
|
||||||
|
|
||||||
```html
|
|
||||||
<a href="#" class="btn btn-primary btn-icon" aria-label="Button">
|
|
||||||
<svg>...</svg>
|
|
||||||
</a>
|
|
||||||
```
|
|
||||||
|
|
||||||
## Dropdown buttons
|
|
||||||
|
|
||||||
Create a dropdown button that will encourage users to click for more options. You can add a label with an icon or remove the label and add an icon on its own if you want to save space. Choose the option that will best suit your design and improve the user experience.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<div class="dropdown">
|
|
||||||
<button type="button" class="btn dropdown-toggle" data-bs-toggle="dropdown">
|
|
||||||
{%- include "ui/icon.html" icon="calendar" -%}
|
|
||||||
</button>
|
|
||||||
<div class="dropdown-menu">
|
|
||||||
<a class="dropdown-item" href="#">Action</a>
|
|
||||||
<a class="dropdown-item" href="#">Another action</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="dropdown">
|
|
||||||
<button type="button" class="btn dropdown-toggle" data-bs-toggle="dropdown">
|
|
||||||
{%- include "ui/icon.html" icon="calendar" -%}
|
|
||||||
Show calendar
|
|
||||||
</button>
|
|
||||||
<div class="dropdown-menu">
|
|
||||||
<a class="dropdown-item" href="#">Action</a>
|
|
||||||
<a class="dropdown-item" href="#">Another action</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="dropdown">
|
|
||||||
<button type="button" class="btn dropdown-toggle" data-bs-toggle="dropdown">Show calendar</button>
|
|
||||||
<div class="dropdown-menu">
|
|
||||||
<a class="dropdown-item" href="#">Action</a>
|
|
||||||
<a class="dropdown-item" href="#">Another action</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered hide-code height="260px" %}
|
|
||||||
|
|
||||||
```html
|
|
||||||
<div class="dropdown">
|
|
||||||
<button type="button" class="btn dropdown-toggle" data-bs-toggle="dropdown">
|
|
||||||
<svg>...</svg>
|
|
||||||
</button>
|
|
||||||
<div class="dropdown-menu">
|
|
||||||
<a class="dropdown-item" href="#">Action</a>
|
|
||||||
<a class="dropdown-item" href="#">Another action</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
```
|
|
||||||
|
|
||||||
## Loading buttons
|
|
||||||
|
|
||||||
Add the `.btn-loading` class to show a button's loading state, which can be useful in the case of operations that take longer to process. Thanks to that, users will be aware of the current state of their action and won't give it up before it's finished.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<a href="#" class="btn btn-primary btn-loading">
|
|
||||||
Button
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-primary btn-loading">
|
|
||||||
Loading button with loooong content
|
|
||||||
</a>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<a href="#" class="btn btn-primary">
|
|
||||||
<span class="spinner-border spinner-border-sm me-2" role="status"></span>
|
|
||||||
Button
|
|
||||||
</a>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Full width buttons
|
|
||||||
|
|
||||||
Add the `.w-100` class to make buttons span the full width of their container. This is useful for mobile-first designs or when you want buttons to take up the entire available space.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<a href="#" class="btn btn-primary w-100">Full width button</a>
|
|
||||||
<a href="#" class="btn btn-outline-secondary w-100">Full width outline button</a>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html separated %}
|
|
||||||
|
|
||||||
## List of buttons
|
|
||||||
|
|
||||||
Create a list of buttons using the `.btn-list` container to display different actions a user can take. If you add additional styling, such as colors, you will be able to focus users' attention on a particular action or suggest the result.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<div class="btn-list">
|
|
||||||
<a href="#" class="btn btn-success">Save changes</a>
|
|
||||||
<a href="#" class="btn">Save and continue</a>
|
|
||||||
<a href="#" class="btn btn-danger">Cancel</a>
|
|
||||||
</div>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
If the list is long, it will be wrapped and some buttons will be moved to the next line, keeping them all evenly spaced.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<div class="btn-list">
|
|
||||||
<a href="#" class="btn">One</a>
|
|
||||||
<a href="#" class="btn">Two</a>
|
|
||||||
<a href="#" class="btn">Three</a>
|
|
||||||
<a href="#" class="btn">Four</a>
|
|
||||||
<a href="#" class="btn">Five</a>
|
|
||||||
<a href="#" class="btn">Six</a>
|
|
||||||
<a href="#" class="btn">Seven</a>
|
|
||||||
<a href="#" class="btn">Eight</a>
|
|
||||||
<a href="#" class="btn">Nine</a>
|
|
||||||
<a href="#" class="btn">Ten</a>
|
|
||||||
<a href="#" class="btn">Eleven</a>
|
|
||||||
<a href="#" class="btn">Twelve</a>
|
|
||||||
<a href="#" class="btn">Thirteen</a>
|
|
||||||
<a href="#" class="btn">Fourteen</a>
|
|
||||||
<a href="#" class="btn">Fifteen</a>
|
|
||||||
<a href="#" class="btn">Sixteen</a>
|
|
||||||
<a href="#" class="btn">Seventeen</a>
|
|
||||||
<a href="#" class="btn">Eighteen</a>
|
|
||||||
<a href="#" class="btn">Nineteen</a>
|
|
||||||
</div>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
Use the `.text-center` or the `.text-end` modifiers to change the buttons' alignment and place them where they suit best.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<div class="btn-list justify-content-center">
|
|
||||||
<a href="#" class="btn">Save and continue</a>
|
|
||||||
<a href="#" class="btn btn-primary">Save changes</a>
|
|
||||||
</div>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html %}
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<div class="btn-list justify-content-end">
|
|
||||||
<a href="#" class="btn">Save and continue</a>
|
|
||||||
<a href="#" class="btn btn-primary">Save changes</a>
|
|
||||||
</div>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html %}
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<div class="btn-list">
|
|
||||||
<a href="#" class="btn btn-outline-danger me-auto">Delete</a>
|
|
||||||
<a href="#" class="btn">Save and continue</a>
|
|
||||||
<a href="#" class="btn btn-primary">Save changes</a>
|
|
||||||
</div>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html %}
|
|
||||||
|
|
||||||
## Buttons with badges
|
|
||||||
|
|
||||||
Add badges to buttons to display additional information like counts, notifications, or status indicators. Badges automatically position themselves within the button layout.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<a href="#" class="btn">
|
|
||||||
Notifications
|
|
||||||
<span class="badge ms-2">14</span>
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn">
|
|
||||||
Messages
|
|
||||||
<span class="badge ms-2">3</span>
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn">
|
|
||||||
Alerts
|
|
||||||
<span class="badge ms-2">7</span>
|
|
||||||
</a>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Buttons with avatars
|
|
||||||
|
|
||||||
Use buttons with avatars to simplify the process of interaction and make your design more personalized. Buttons can contain avatars and labels or only avatars, if displayed on a smaller space.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<a href="#" class="btn">
|
|
||||||
<span
|
|
||||||
class="avatar"
|
|
||||||
style="background-image: url(/static/avatars/002f.jpg);"
|
|
||||||
></span>
|
|
||||||
Avatar
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn">
|
|
||||||
<span
|
|
||||||
class="avatar"
|
|
||||||
style="
|
|
||||||
background-image: url(/static/avatars/002m.jpg);
|
|
||||||
"
|
|
||||||
></span>
|
|
||||||
Avatar
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn">
|
|
||||||
<span
|
|
||||||
class="avatar"
|
|
||||||
style="
|
|
||||||
background-image: url(/static/avatars/004f.jpg);
|
|
||||||
"
|
|
||||||
></span>
|
|
||||||
Avatar
|
|
||||||
</a>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Buttons with animations on hover
|
|
||||||
|
|
||||||
Add a subtle animation effect to your buttons when users hover over them. This can enhance the interactivity and provide visual feedback to improve the user experience.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<div class="btn-list">
|
|
||||||
<a class="btn btn-animate-icon">
|
|
||||||
Save {% include "ui/icon.html" icon="arrow-right" class="icon-end" %}
|
|
||||||
</a>
|
|
||||||
<a class="btn btn-animate-icon btn-animate-icon-rotate">
|
|
||||||
{% include "ui/icon.html" icon="plus" %} Add
|
|
||||||
</a>
|
|
||||||
<a class="btn btn-animate-icon btn-animate-icon-shake">
|
|
||||||
{% include "ui/icon.html" icon="bell" %} Notifications
|
|
||||||
</a>
|
|
||||||
<a class="btn btn-animate-icon btn-animate-icon-rotate">
|
|
||||||
{% include "ui/icon.html" icon="settings" %} Settings
|
|
||||||
</a>
|
|
||||||
<a class="btn btn-animate-icon btn-animate-icon-pulse">
|
|
||||||
{% include "ui/icon.html" icon="heart" %} Love
|
|
||||||
</a>
|
|
||||||
<a class="btn btn-animate-icon btn-animate-icon-rotate">
|
|
||||||
{% include "ui/icon.html" icon="x" %} Close
|
|
||||||
</a>
|
|
||||||
<a class="btn btn-animate-icon btn-animate-icon-tada">
|
|
||||||
{% include "ui/icon.html" icon="check" %} Confirm
|
|
||||||
</a>
|
|
||||||
<a class="btn btn-animate-icon">
|
|
||||||
Next {% include "ui/icon.html" icon="chevron-right" class="icon-end" %}
|
|
||||||
</a>
|
|
||||||
<a class="btn btn-animate-icon btn-animate-icon-move-start">
|
|
||||||
{% include "ui/icon.html" icon="chevron-left" %} Previous
|
|
||||||
</a>
|
|
||||||
</div>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html %}
|
|
||||||
|
|
||||||
## Button sizes
|
|
||||||
|
|
||||||
Use size modifiers to change the size of your buttons. Available sizes: `.btn-xs`, `.btn-sm`, default, `.btn-lg`, `.btn-xl`.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<button type="button" class="btn btn-sm">Small button</button>
|
|
||||||
<button type="button" class="btn">Default button</button>
|
|
||||||
<button type="button" class="btn btn-lg">Large button</button>
|
|
||||||
<button type="button" class="btn btn-xl">Extra large button</button>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html separated centered vertical %}
|
|
||||||
|
|
||||||
## Link buttons
|
|
||||||
|
|
||||||
Use the `.btn-link` class to create buttons that look like links but maintain button functionality. These are useful for secondary actions that shouldn't compete with primary buttons for attention.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<a href="#" class="btn btn-link">Link button</a>
|
|
||||||
<button type="button" class="btn btn-link">Link button</button>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Action buttons
|
|
||||||
|
|
||||||
Use the `.btn-action` class to create subtle action buttons that are perfect for card headers, toolbars, or other interface elements where you want minimal visual impact.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<div class="btn-actions">
|
|
||||||
<a href="#" class="btn btn-action" aria-label="Edit">
|
|
||||||
{%- include "ui/icon.html" icon="edit" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-action" aria-label="Copy">
|
|
||||||
{%- include "ui/icon.html" icon="copy" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-action" aria-label="Settings">
|
|
||||||
{%- include "ui/icon.html" icon="settings" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-action" aria-label="Delete">
|
|
||||||
{%- include "ui/icon.html" icon="trash" -%}
|
|
||||||
</a>
|
|
||||||
</div>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Action button groups
|
|
||||||
|
|
||||||
Use the `.btn-actions` container to group multiple action buttons together. This creates a cohesive set of related actions that work well in card headers, toolbars, or other interface elements.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<div class="btn-actions">
|
|
||||||
<a href="#" class="btn btn-action">
|
|
||||||
{%- include "ui/icon.html" icon="refresh" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-action">
|
|
||||||
{%- include "ui/icon.html" icon="chevron-up" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-action">
|
|
||||||
{%- include "ui/icon.html" icon="dots-vertical" -%}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="btn btn-action">
|
|
||||||
{%- include "ui/icon.html" icon="x" -%}
|
|
||||||
</a>
|
|
||||||
</div>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
## Button groups
|
|
||||||
|
|
||||||
Use button groups to combine related buttons together. Button groups are perfect for creating toolbars, segmented controls, or any interface where multiple related actions should be visually grouped.
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<div class="btn-group" role="group">
|
|
||||||
<button type="button" class="btn">Left</button>
|
|
||||||
<button type="button" class="btn">Middle</button>
|
|
||||||
<button type="button" class="btn">Right</button>
|
|
||||||
</div>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<div class="btn-group" role="group">
|
|
||||||
<input type="radio" class="btn-check" name="btn-radio" id="btn-radio-1" autocomplete="off" checked>
|
|
||||||
<label class="btn" for="btn-radio-1">Radio 1</label>
|
|
||||||
|
|
||||||
<input type="radio" class="btn-check" name="btn-radio" id="btn-radio-2" autocomplete="off">
|
|
||||||
<label class="btn" for="btn-radio-2">Radio 2</label>
|
|
||||||
|
|
||||||
<input type="radio" class="btn-check" name="btn-radio" id="btn-radio-3" autocomplete="off">
|
|
||||||
<label class="btn" for="btn-radio-3">Radio 3</label>
|
|
||||||
</div>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered %}
|
|
||||||
|
|
||||||
{% capture html -%}
|
|
||||||
<div class="btn-group-vertical" role="group">
|
|
||||||
<button type="button" class="btn">Top</button>
|
|
||||||
<button type="button" class="btn">Middle</button>
|
|
||||||
<button type="button" class="btn">Bottom</button>
|
|
||||||
</div>
|
|
||||||
{%- endcapture -%}
|
|
||||||
{%- include "docs/example.html" html=html centered %}
|
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user