refactor: optimize icon bundle size, update icons
This commit is contained in:
parent
8c0deeed16
commit
9fed168a53
@ -2,8 +2,252 @@ import { sygnet } from './sygnet'
|
||||
import { logo } from './logo'
|
||||
import { logoNegative } from './logo-negative'
|
||||
|
||||
export {
|
||||
import {
|
||||
cibSkype,
|
||||
cibFacebook,
|
||||
cibTwitter,
|
||||
cibLinkedin,
|
||||
cibFlickr,
|
||||
cibTumblr,
|
||||
cibXing,
|
||||
cibGithub,
|
||||
cibStackOverflow,
|
||||
cibYoutube,
|
||||
cibDribbble,
|
||||
cibInstagram,
|
||||
cibPinterest,
|
||||
cibVk,
|
||||
cibYahoo,
|
||||
cibBehance,
|
||||
cibReddit,
|
||||
cibVimeo,
|
||||
cibCcMastercard,
|
||||
cibCcVisa,
|
||||
cibStripe,
|
||||
cibPaypal,
|
||||
cibGooglePay,
|
||||
cibCcAmex
|
||||
} from '@coreui/icons'
|
||||
import {
|
||||
cifUs,
|
||||
cifBr,
|
||||
cifIn,
|
||||
cifFr,
|
||||
cifEs,
|
||||
cifPl
|
||||
} from '@coreui/icons'
|
||||
import {
|
||||
cilAlignCenter,
|
||||
cilAlignLeft,
|
||||
cilAlignRight,
|
||||
cilApplicationsSettings,
|
||||
cilArrowRight,
|
||||
cilBan,
|
||||
cilBasket,
|
||||
cilBell,
|
||||
cilBold,
|
||||
cilBookmark,
|
||||
cilCalculator,
|
||||
cilCalendar,
|
||||
cilCloudDownload,
|
||||
cilChartPie,
|
||||
cilCheck,
|
||||
cilChevronBottom,
|
||||
cilChevronLeft,
|
||||
cilChevronRight,
|
||||
cilChevronTop,
|
||||
cilCircle,
|
||||
cilCheckCircle,
|
||||
cilCode,
|
||||
cilCommentSquare,
|
||||
cilCreditCard,
|
||||
cilCursor,
|
||||
cilCursorMove,
|
||||
cilDrop,
|
||||
cilDollar,
|
||||
cilEnvelopeClosed,
|
||||
cilEnvelopeLetter,
|
||||
cilEnvelopeOpen,
|
||||
cilEuro,
|
||||
cilGlobeAlt,
|
||||
cilGrid,
|
||||
cilFile,
|
||||
cilFullscreen,
|
||||
cilFullscreenExit,
|
||||
cilGraph,
|
||||
cilHome,
|
||||
cilInbox,
|
||||
cilIndentDecrease,
|
||||
cilIndentIncrease,
|
||||
cilInputPower,
|
||||
cilItalic,
|
||||
cilJustifyCenter,
|
||||
cilJustifyLeft,
|
||||
cilLaptop,
|
||||
cilLayers,
|
||||
cilLightbulb,
|
||||
cilList,
|
||||
cilListNumbered,
|
||||
cilListRich,
|
||||
cilLocationPin,
|
||||
cilLockLocked,
|
||||
cilMagnifyingGlass,
|
||||
cilMap,
|
||||
cilMoon,
|
||||
cilNotes,
|
||||
cilOptions,
|
||||
cilPaperclip,
|
||||
cilPaperPlane,
|
||||
cilPencil,
|
||||
cilPeople,
|
||||
cilPhone,
|
||||
cilPrint,
|
||||
cilPuzzle,
|
||||
cilSave,
|
||||
cilSettings,
|
||||
cilShare,
|
||||
cilShareAll,
|
||||
cilShareBoxed,
|
||||
cilShieldAlt,
|
||||
cilSpeech,
|
||||
cilSpeedometer,
|
||||
cilSpreadsheet,
|
||||
cilStar,
|
||||
cilSun,
|
||||
cilTags,
|
||||
cilTask,
|
||||
cilTrash,
|
||||
cilUnderline,
|
||||
cilUser,
|
||||
cilUserFemale,
|
||||
cilUserFollow,
|
||||
cilUserUnfollow,
|
||||
cilXCircle,
|
||||
cilWarning
|
||||
} from '@coreui/icons'
|
||||
|
||||
export const icons = Object.assign({}, {
|
||||
sygnet,
|
||||
logo,
|
||||
logoNegative
|
||||
}
|
||||
}, {
|
||||
cilAlignCenter,
|
||||
cilAlignLeft,
|
||||
cilAlignRight,
|
||||
cilApplicationsSettings,
|
||||
cilArrowRight,
|
||||
cilBan,
|
||||
cilBasket,
|
||||
cilBell,
|
||||
cilBold,
|
||||
cilBookmark,
|
||||
cilCalculator,
|
||||
cilCalendar,
|
||||
cilCloudDownload,
|
||||
cilChartPie,
|
||||
cilCheck,
|
||||
cilChevronBottom,
|
||||
cilChevronLeft,
|
||||
cilChevronRight,
|
||||
cilChevronTop,
|
||||
cilCircle,
|
||||
cilCheckCircle,
|
||||
cilCode,
|
||||
cilCommentSquare,
|
||||
cilCreditCard,
|
||||
cilCursor,
|
||||
cilCursorMove,
|
||||
cilDrop,
|
||||
cilDollar,
|
||||
cilEnvelopeClosed,
|
||||
cilEnvelopeLetter,
|
||||
cilEnvelopeOpen,
|
||||
cilEuro,
|
||||
cilGraph,
|
||||
cilGlobeAlt,
|
||||
cilGrid,
|
||||
cilFile,
|
||||
cilFullscreen,
|
||||
cilFullscreenExit,
|
||||
cilHome,
|
||||
cilInbox,
|
||||
cilIndentDecrease,
|
||||
cilIndentIncrease,
|
||||
cilInputPower,
|
||||
cilItalic,
|
||||
cilJustifyCenter,
|
||||
cilJustifyLeft,
|
||||
cilLaptop,
|
||||
cilLayers,
|
||||
cilLightbulb,
|
||||
cilList,
|
||||
cilListNumbered,
|
||||
cilListRich,
|
||||
cilLocationPin,
|
||||
cilLockLocked,
|
||||
cilMagnifyingGlass,
|
||||
cilMap,
|
||||
cilMoon,
|
||||
cilNotes,
|
||||
cilOptions,
|
||||
cilPaperclip,
|
||||
cilPaperPlane,
|
||||
cilPencil,
|
||||
cilPeople,
|
||||
cilPhone,
|
||||
cilPrint,
|
||||
cilPuzzle,
|
||||
cilSave,
|
||||
cilSettings,
|
||||
cilShare,
|
||||
cilShareAll,
|
||||
cilShareBoxed,
|
||||
cilShieldAlt,
|
||||
cilSpeech,
|
||||
cilSpeedometer,
|
||||
cilSpreadsheet,
|
||||
cilStar,
|
||||
cilSun,
|
||||
cilTags,
|
||||
cilTask,
|
||||
cilTrash,
|
||||
cilUnderline,
|
||||
cilUser,
|
||||
cilUserFemale,
|
||||
cilUserFollow,
|
||||
cilUserUnfollow,
|
||||
cilXCircle,
|
||||
cilWarning
|
||||
}, {
|
||||
cifUs,
|
||||
cifBr,
|
||||
cifIn,
|
||||
cifFr,
|
||||
cifEs,
|
||||
cifPl
|
||||
}, {
|
||||
cibSkype,
|
||||
cibFacebook,
|
||||
cibTwitter,
|
||||
cibLinkedin,
|
||||
cibFlickr,
|
||||
cibTumblr,
|
||||
cibXing,
|
||||
cibGithub,
|
||||
cibStackOverflow,
|
||||
cibYoutube,
|
||||
cibDribbble,
|
||||
cibInstagram,
|
||||
cibPinterest,
|
||||
cibVk,
|
||||
cibYahoo,
|
||||
cibBehance,
|
||||
cibReddit,
|
||||
cibVimeo,
|
||||
cibCcMastercard,
|
||||
cibCcVisa,
|
||||
cibStripe,
|
||||
cibPaypal,
|
||||
cibGooglePay,
|
||||
cibCcAmex
|
||||
})
|
||||
|
12
src/index.js
12
src/index.js
@ -6,20 +6,12 @@ import ReactDOM from 'react-dom';
|
||||
import App from './App';
|
||||
import * as serviceWorker from './serviceWorker';
|
||||
|
||||
import { freeSet, flagSet, brandSet } from '@coreui/icons';
|
||||
import { logo, logoNegative, sygnet } from './assets/icons'
|
||||
import { icons } from './assets/icons'
|
||||
|
||||
import { Provider } from 'react-redux'
|
||||
import store from './store'
|
||||
|
||||
React.icons = {
|
||||
...freeSet,
|
||||
...flagSet,
|
||||
...brandSet,
|
||||
logo,
|
||||
logoNegative,
|
||||
sygnet
|
||||
}
|
||||
React.icons = icons
|
||||
|
||||
ReactDOM.render(
|
||||
<Provider store={store}>
|
||||
|
@ -360,7 +360,7 @@ const Dashboard = () => {
|
||||
<CProgress className="progress-xs" color="success" value="50" />
|
||||
</td>
|
||||
<td className="text-center">
|
||||
<CIcon height={25} name="cib-mastercard" />
|
||||
<CIcon height={25} name="cib-cc-mastercard" />
|
||||
</td>
|
||||
<td>
|
||||
<div className="small text-muted">Last login</div>
|
||||
@ -396,7 +396,7 @@ const Dashboard = () => {
|
||||
<CProgress className="progress-xs" color="info" value="10" />
|
||||
</td>
|
||||
<td className="text-center">
|
||||
<CIcon height={25} name="cib-visa" />
|
||||
<CIcon height={25} name="cib-cc-visa" />
|
||||
</td>
|
||||
<td>
|
||||
<div className="small text-muted">Last login</div>
|
||||
@ -501,7 +501,7 @@ const Dashboard = () => {
|
||||
<CProgress className="progress-xs" color="info" value="22" />
|
||||
</td>
|
||||
<td className="text-center">
|
||||
<CIcon height={25} name="cil-wallet"/>
|
||||
<CIcon height={25} name="cib-google-pay"/>
|
||||
</td>
|
||||
<td>
|
||||
<div className="small text-muted">Last login</div>
|
||||
|
Loading…
Reference in New Issue
Block a user