Repository URL to install this package:
|
Version:
2.7.8 ▾
|
<!doctype html>
<html lang="en">
<head>
<title>Code coverage report for src/inputs/TextBox/deps/toAttributes.ts</title>
<meta charset="utf-8" />
<link rel="stylesheet" href="../../../../prettify.css" />
<link rel="stylesheet" href="../../../../base.css" />
<meta name="viewport" content="width=device-width, initial-scale=1">
<style type='text/css'>
.coverage-summary .sorter {
background-image: url(../../../../sort-arrow-sprite.png);
}
</style>
</head>
<body>
<div class='wrapper'>
<div class='pad1'>
<h1>
<a href="../../../../index.html">All files</a> / <a href="index.html">src/inputs/TextBox/deps</a> toAttributes.ts
</h1>
<div class='clearfix'>
<div class='fl pad1y space-right2'>
<span class="strong">0% </span>
<span class="quiet">Statements</span>
<span class='fraction'>0/29</span>
</div>
<div class='fl pad1y space-right2'>
<span class="strong">100% </span>
<span class="quiet">Branches</span>
<span class='fraction'>0/0</span>
</div>
<div class='fl pad1y space-right2'>
<span class="strong">0% </span>
<span class="quiet">Functions</span>
<span class='fraction'>0/1</span>
</div>
<div class='fl pad1y space-right2'>
<span class="strong">0% </span>
<span class="quiet">Lines</span>
<span class='fraction'>0/29</span>
</div>
</div>
</div>
<div class='status-line low'></div>
<pre><table class="coverage">
<tr><td class="line-count quiet">1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52</td><td class="line-coverage quiet"><span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-no"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-neutral"> </span>
<span class="cline-any cline-neutral"> </span></td><td class="text"><pre class="prettyprint lang-js">/* eslint-disable max-statements */
/* @lint - is a bunch of getters */
import { TextBoxProps, TextBoxState, TextBoxComponent } from '../typings'
<span class="cstat-no" title="statement not covered" >import { toErrorProps } from './toErrorProps'</span>
<span class="cstat-no" title="statement not covered" >import { toClassList } from './toClassList'</span>
<span class="cstat-no" title="statement not covered" >import { toPassThroughProps } from './toPassThroughProps'</span>
<span class="cstat-no" title="statement not covered" >import { toValidationProps } from './toValidationProps'</span>
<span class="cstat-no" title="statement not covered" >import { toType } from './toType'</span>
<span class="cstat-no" title="statement not covered" >import { createGetFromPropsOrState } from './createGetFromPropsOrState'</span>
<span class="cstat-no" title="statement not covered" >import { toPlaceholder } from './toPlaceholder'</span>
<span class="cstat-no" title="statement not covered" >import { toAccessibleAttributes } from './toAccessibleProps'</span>
<span class="cstat-no" title="statement not covered" >import { toAriaLabel } from './toAriaLabel'</span>
<span class="cstat-no" title="statement not covered" >export function <span class="fstat-no" title="function not covered" >toAttributes(</span>instance: TextBoxComponent) {</span>
const { props, state } = <span class="cstat-no" title="statement not covered" >instance</span>
const classList = <span class="cstat-no" title="statement not covered" >toClassList(props, state)</span>
const passthroughProps = <span class="cstat-no" title="statement not covered" >toPassThroughProps(props, state)</span>
const validationProps = <span class="cstat-no" title="statement not covered" >toValidationProps(props, state)</span>
const type = <span class="cstat-no" title="statement not covered" >toType(props, state)</span>
const get = <span class="cstat-no" title="statement not covered" >createGetFromPropsOrState(instance)</span>
const placeholderText = <span class="cstat-no" title="statement not covered" >toPlaceholder(props, state)</span>
const accessibleProps = <span class="cstat-no" title="statement not covered" >toAccessibleAttributes(props, state)</span>
const { hasError } = <span class="cstat-no" title="statement not covered" >toErrorProps(props, state)</span>
const animatePlaceholder = <span class="cstat-no" title="statement not covered" >get('animatePlaceholder')</span>
const name = <span class="cstat-no" title="statement not covered" >get('name')</span>
const isDisabled = <span class="cstat-no" title="statement not covered" >get('isDisabled')</span>
// @todo should not come like this, should go as passthroughProps
const dataQa = <span class="cstat-no" title="statement not covered" >get('dataQa')</span>
const qa = <span class="cstat-no" title="statement not covered" >get('qa')</span>
const wrapperProps<span class="cstat-no" title="statement not covered" > = { ...accessibleProps, hasError }</span>
const labelText = <span class="cstat-no" title="statement not covered" >get('labelText')</span>
const ariaLabel = <span class="cstat-no" title="statement not covered" >toAriaLabel(props, state)</span>
const inputIcon = <span class="cstat-no" title="statement not covered" >get('icon')</span>
<span class="cstat-no" title="statement not covered" > return {</span>
passthroughProps,
wrapperProps,
validationProps,
classList,
placeholderText,
animatePlaceholder,
name,
isDisabled,
type,
dataQa,
qa,
labelText,
ariaLabel,
inputIcon,
}
}
</pre></td></tr>
</table></pre>
<div class='push'></div><!-- for sticky footer -->
</div><!-- /wrapper -->
<div class='footer quiet pad2 space-top1 center small'>
Code coverage
generated by <a href="https://istanbul.js.org/" target="_blank">istanbul</a> at Sun Nov 25 2018 21:37:17 GMT+0530 (India Standard Time)
</div>
</div>
<script src="../../../../prettify.js"></script>
<script>
window.onload = function () {
if (typeof prettyPrint === 'function') {
prettyPrint();
}
};
</script>
<script src="../../../../sorter.js"></script>
</body>
</html>