1 | {"version":3,"file":"PulsingBeaconAnimationStyles.js","sourceRoot":"../src/","sources":["styles/PulsingBeaconAnimationStyles.ts"],"names":[],"mappings":";;;AAAA,uDAA8D;AAE9D,IAAM,gBAAgB,GAAG,KAAK,CAAC;AAC/B,IAAM,aAAa,GAAG,IAAI,CAAC;AAC3B,IAAM,uBAAuB,GAAG,GAAG,CAAC;AAEpC,SAAS,uBAAuB,CAAC,cAAsB,EAAE,cAAsB;IAC7E,OAAO;QACL,WAAW,EAAE,cAAc;QAC3B,WAAW,EAAE,KAAK;QAClB,KAAK,EAAE,cAAc;QACrB,MAAM,EAAE,cAAc;KACvB,CAAC;AACJ,CAAC;AAED,SAAS,uBAAuB,CAAC,WAAmB;IAClD,OAAO;QACL,OAAO,EAAE,CAAC;QACV,WAAW,EAAE,WAAW;KACzB,CAAC;AACJ,CAAC;AAED,SAAS,yBAAyB;IAChC,OAAO;QACL,OAAO,EAAE,CAAC;KACX,CAAC;AACJ,CAAC;AAED,SAAS,wBAAwB,CAAC,cAAsB,EAAE,cAAsB;IAC9E,OAAO;QACL,WAAW,EAAE,GAAG;QAChB,KAAK,EAAE,cAAc;QACrB,MAAM,EAAE,cAAc;QACtB,OAAO,EAAE,CAAC;QACV,WAAW,EAAE,cAAc;KAC5B,CAAC;AACJ,CAAC;AAED,SAAS,wBAAwB,CAAC,cAAsB,EAAE,cAAsB;IAC9E,6CACK,uBAAuB,CAAC,cAAc,EAAE,cAAc,CAAC,GACvD;QACD,OAAO,EAAE,CAAC;KACX,EACD;AACJ,CAAC;AAED,SAAS,+BAA+B,CACtC,cAAsB,EACtB,cAAsB,EACtB,cAAsB,EACtB,cAAsB,EACtB,WAAmB;IAEnB,OAAO,wBAAS,CAAC;QACf,IAAI,EAAE,uBAAuB,CAAC,cAAc,EAAE,cAAc,CAAC;QAC7D,OAAO,EAAE,uBAAuB,CAAC,WAAW,CAAC;QAC7C,OAAO,EAAE,yBAAyB,EAAE;QACpC,OAAO,EAAE,wBAAwB,CAAC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;AACJ,CAAC;AAEY,QAAA,4BAA4B,GAAG;IAC1C,8BAA8B,EAAE,+BAA+B;IAC/D,8BAA8B,EAAE,+BAA+B;IAC/D,sBAAsB,EAAE,uBAAuB;CAChD,CAAC","sourcesContent":["import { IRawStyle, keyframes } from '@uifabric/merge-styles';\n\nconst DEFAULT_DURATION = '14s';\nconst DEFAULT_DELAY = '2s';\nconst DEFAULT_ITERATION_COUNT = '1';\n\nfunction _continuousPulseStepOne(beaconColorOne: string, innerDimension: string): IRawStyle {\n return {\n borderColor: beaconColorOne,\n borderWidth: '0px',\n width: innerDimension,\n height: innerDimension,\n };\n}\n\nfunction _continuousPulseStepTwo(borderWidth: string): IRawStyle {\n return {\n opacity: 1,\n borderWidth: borderWidth,\n };\n}\n\nfunction _continuousPulseStepThree(): IRawStyle {\n return {\n opacity: 1,\n };\n}\n\nfunction _continuousPulseStepFour(beaconColorTwo: string, outerDimension: string): IRawStyle {\n return {\n borderWidth: '0',\n width: outerDimension,\n height: outerDimension,\n opacity: 0,\n borderColor: beaconColorTwo,\n };\n}\n\nfunction _continuousPulseStepFive(beaconColorOne: string, innerDimension: string): IRawStyle {\n return {\n ..._continuousPulseStepOne(beaconColorOne, innerDimension),\n ...{\n opacity: 0,\n },\n };\n}\n\nfunction _continuousPulseAnimationDouble(\n beaconColorOne: string,\n beaconColorTwo: string,\n innerDimension: string,\n outerDimension: string,\n borderWidth: string,\n): string {\n return keyframes({\n '0%': _continuousPulseStepOne(beaconColorOne, innerDimension),\n '1.42%': _continuousPulseStepTwo(borderWidth),\n '3.57%': _continuousPulseStepThree(),\n '7.14%': _continuousPulseStepFour(beaconColorTwo, outerDimension),\n '8%': _continuousPulseStepFive(beaconColorOne, innerDimension),\n '29.99%': _continuousPulseStepFive(beaconColorOne, innerDimension),\n '30%': _continuousPulseStepOne(beaconColorOne, innerDimension),\n '31.42%': _continuousPulseStepTwo(borderWidth),\n '33.57%': _continuousPulseStepThree(),\n '37.14%': _continuousPulseStepFour(beaconColorTwo, outerDimension),\n '38%': _continuousPulseStepFive(beaconColorOne, innerDimension),\n '79.42%': _continuousPulseStepFive(beaconColorOne, innerDimension),\n '79.43': _continuousPulseStepOne(beaconColorOne, innerDimension),\n '81.85': _continuousPulseStepTwo(borderWidth),\n '83.42': _continuousPulseStepThree(),\n '87%': _continuousPulseStepFour(beaconColorTwo, outerDimension),\n '100%': {},\n });\n}\n\nfunction _continuousPulseAnimationSingle(\n beaconColorOne: string,\n beaconColorTwo: string,\n innerDimension: string,\n outerDimension: string,\n borderWidth: string,\n): string {\n return keyframes({\n '0%': _continuousPulseStepOne(beaconColorOne, innerDimension),\n '14.2%': _continuousPulseStepTwo(borderWidth),\n '35.7%': _continuousPulseStepThree(),\n '71.4%': _continuousPulseStepFour(beaconColorTwo, outerDimension),\n '100%': {},\n });\n}\n\nfunction _createDefaultAnimation(animationName: string, delayLength?: string): IRawStyle {\n return {\n animationName,\n animationIterationCount: DEFAULT_ITERATION_COUNT,\n animationDuration: DEFAULT_DURATION,\n animationDelay: delayLength || DEFAULT_DELAY,\n };\n}\n\nexport const PulsingBeaconAnimationStyles = {\n continuousPulseAnimationDouble: _continuousPulseAnimationDouble,\n continuousPulseAnimationSingle: _continuousPulseAnimationSingle,\n createDefaultAnimation: _createDefaultAnimation,\n};\n"]} |