ahmedelgabri
Advanced tools
Comparing version 4.0.0-2 to 4.0.0-3
66
index.js
@@ -1,15 +0,51 @@ | ||
export const card = ` | ||
╭─────────────────────────────────────────────────────────╮ | ||
│ │ | ||
│ Ahmed El Gabri / ahmedelgabri │ | ||
│ │ | ||
│ Work: Tech Lead, Platform @Mirohq │ | ||
│ Twitter: https://twitter.com/ahmedelgabri │ | ||
│ GitHub: https://github.com/ahmedelgabri │ | ||
│ LinkedIn: https://linkedin.com/in/ahmedelgabri │ | ||
│ Web: https://gabri.me │ | ||
│ │ | ||
│ Card: npx ahmedelgabri │ | ||
│ │ | ||
╰─────────────────────────────────────────────────────────╯ | ||
` | ||
const chalk = require('chalk') | ||
const boxen = require('boxen') | ||
// Define options for Boxen | ||
const options = { | ||
padding: 1, | ||
margin: 1, | ||
borderStyle: 'round', | ||
} | ||
// Text + chalk definitions | ||
const data = { | ||
name: chalk.white('Ahmed El Gabri /'), | ||
handle: chalk.cyan('ahmedelgabri'), | ||
work: chalk.white('Tech Lead, Platform @Mirohq'), | ||
twitter: chalk.cyan('https://twitter.com/ahmedelgabri'), | ||
github: chalk.cyan('https://github.com/ahmedelgabri'), | ||
linkedin: chalk.cyan('https://linkedin.com/in/ahmedelgabri'), | ||
web: chalk.cyan('https://gabri.me'), | ||
npx: chalk.white('npx ahmedelgabri'), | ||
labelWork: chalk.white.bold(' Work: '), | ||
labelTwitter: chalk.white.bold(' Twitter: '), | ||
labelGitHub: chalk.white.bold(' GitHub: '), | ||
labelLinkedIn: chalk.white.bold(' LinkedIn: '), | ||
labelWeb: chalk.white.bold(' Web: '), | ||
labelCard: chalk.white.bold(' Card: '), | ||
} | ||
// Actual strings we're going to output | ||
const heading = `${data.name} ${data.handle}` | ||
const working = `${data.labelWork} ${data.work}` | ||
const twittering = `${data.labelTwitter} ${data.twitter}` | ||
const githubing = `${data.labelGitHub} ${data.github}` | ||
const linkedining = `${data.labelLinkedIn} ${data.linkedin}` | ||
const webing = `${data.labelWeb} ${data.web}` | ||
const carding = `${data.labelCard} ${data.npx}` | ||
// Put all our output together into a single variable so we can use boxen effectively | ||
const output = `${heading} | ||
${working} | ||
${twittering} | ||
${githubing} | ||
${linkedining} | ||
${webing} | ||
${carding}` | ||
module.exports = { | ||
getCard: () => chalk.green(boxen(output, options)), | ||
} |
{ | ||
"name": "ahmedelgabri", | ||
"author": "Ahmed El Gabri <ahmed@gabri.me> (https://gabri.me)", | ||
"version": "4.0.0-2", | ||
"version": "4.0.0-3", | ||
"description": "A personal card for Ahmed El Gabri (@ahmedelgabri)", | ||
"license": "MIT", | ||
"homepage": "https://gabri.me", | ||
"main": "index.cjs.js", | ||
"browser": "index.js", | ||
"main": "index.js", | ||
"bin": { | ||
@@ -30,4 +29,3 @@ "ahmedelgabri": "./bin/card.js" | ||
"bin/output", | ||
"index.js", | ||
"index.cjs.js" | ||
"index.js" | ||
], | ||
@@ -34,0 +32,0 @@ "repository": { |
50
5139
6