(options)
| 28 | } |
| 29 | |
| 30 | export function getGrid(options) { |
| 31 | if (!options) { |
| 32 | return ''; |
| 33 | } |
| 34 | if (typeof options === 'number') { |
| 35 | options = { width: options }; |
| 36 | } |
| 37 | |
| 38 | let { width, offset, responsive } = options; |
| 39 | let gridClass = generate(width, 'grid', responsive); |
| 40 | let offsetClass = generate(offset, 'offset', responsive); |
| 41 | |
| 42 | return `${gridPre} ${gridPre}-1 ${gridClass} ${offsetClass}`; |
| 43 | } |
| 44 | |
| 45 | function generate(width, type, responsive) { |
| 46 | if (!width || width <= 0) { |
no test coverage detected
searching dependent graphs…