( chalkInstance: Chalk, )
| 65 | }; |
| 66 | |
| 67 | export const getReceivedColorForChalkInstance = ( |
| 68 | chalkInstance: Chalk, |
| 69 | ): DiffOptionsColor => { |
| 70 | const level = chalkInstance.level; |
| 71 | |
| 72 | if (level === 3) { |
| 73 | return chalkInstance |
| 74 | .rgb(bForeground3[0], bForeground3[1], bForeground3[2]) |
| 75 | .bgRgb(bBackground3[0], bBackground3[1], bBackground3[2]); |
| 76 | } |
| 77 | |
| 78 | if (level === 2) { |
| 79 | return chalkInstance.ansi256(bForeground2).bgAnsi256(bBackground2); |
| 80 | } |
| 81 | |
| 82 | return chalkInstance.cyan.bgWhiteBright; // also known as teal |
| 83 | }; |
| 84 | |
| 85 | export const aSnapshotColor = getSnapshotColorForChalkInstance(chalk); |
| 86 | export const bReceivedColor = getReceivedColorForChalkInstance(chalk); |
no outgoing calls