Showing 3,724 of 12,672 total issues
Function SSNWidget
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export default function SSNWidget(props) {
const [val, setVal] = useState(props.value);
const [displayVal, setDisplayVal] = useState(props.value);
const handleChange = value => {
Function validatePages
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function validatePages(orderedPageTypes) {
const pageTypes = {};
for (const pageType of orderedPageTypes) {
if (pageType === 'intro') {
if (pageTypes.intro || pageTypes.summary || pageTypes.item) {
Function accessibleFieldContent
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
{this.orderedProperties.map((objectFields, index) => {
if (objectFields.length > 1) {
const [first, ...rest] = objectFields;
const visible = rest.filter(
prop => !schema.properties[prop]['ui:collapsed'],
Function Submitted
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export default function Submitted(props) {
const { formConfig, onBack, onSubmit } = props;
let ariaDescribedBy = null;
// If no ariaDescribedBy is passed down from form.js,
// a null value will properly not render the aria label.
Function recordPanEvent
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export const recordPanEvent = (mapCenter, currentQuery) => {
const { searchCoords, searchArea } = currentQuery;
return new Promise((resolve, _) => {
let distanceMoved;
Function formatReadableDate
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export const formatReadableDate = (rawDate, minimumDateDigits = 1) => {
const months = [
'January',
'February',
'March',
Function CustomPhoneNumberField
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function CustomPhoneNumberField(props) {
function handleChange(event) {
if (props?.showMebEnhancements08) {
props?.updateGlobalPhoneNumber(event);
if (event?.length > 9) {
Function DebtCardsList
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const DebtCardsList = () => {
const { debts } = useSelector(
({ combinedPortal }) => combinedPortal.debtLetters,
);
Function ContestableIssuesWidget
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const ContestableIssuesWidget = props => {
const {
getContestableIssues,
contestableIssues,
setFormData,
Function transform
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function transform(formConfig, form) {
// https://developer.va.gov/explore/appeals/docs/decision_reviews?version=current
// match supplemental claims schema here
const mainTransform = formData => {
const { benefitType, additionalDocuments } = formData;
Function transform
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function transform(formConfig, form) {
// https://developer.va.gov/explore/appeals/docs/decision_reviews?version=current
// match supplemental claims schema here
const mainTransform = formData => {
const { benefitType, additionalDocuments } = formData;
Function processContestableIssues
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export const processContestableIssues = contestableIssues => {
const processDate = entry =>
(entry.attributes?.approxDecisionDate || '').replace(REGEXP.DASH, '');
// remove issues with no title & sort by date - see
// https://dsva.slack.com/archives/CSKKUL36K/p1623956682119300
Function contestableIssuesReducer
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const contestableIssuesReducer = getEligibleContestableIssues => (
state = initialState,
action,
) => {
switch (action?.type) {
Function DependentListLoopForm
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const DependentListLoopForm = props => {
const { children, data, page, onChange, onSubmit } = props;
const { fullName = {} } = data || {};
// build the uiSchema title attribute based on form & page data
Function DependentListLoopForm
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const DependentListLoopForm = props => {
const { children, data, page, onChange, onSubmit } = props;
const { fullName = {} } = data || {};
// build the uiSchema title attribute based on form & page data
Function LastUpdated
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const LastUpdated = () => {
const feedbackButtonClicked = () => {
window.KAMPYLE_ONSITE_SDK?.showForm('17');
};
Function getEmptyState
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
getEmptyState(props) {
const {
onEdit,
hideTitle,
title,
Function libraryPagerGen
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function libraryPagerGen() {
const numCardsCount = libraryNumActiveCards();
numCards = libraryNumCards();
pages = Math.ceil(numCardsCount / itemsPerPage);
if (document.getElementById('pager-nums-insert')) {
Function ConfirmationPage
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const ConfirmationPage = () => {
const { submission, data } = useSelector(state => state.form);
const { userFullName } = useSelector(selectProfile);
const loggedIn = useSelector(isLoggedIn);
const { response } = submission;
Function labResults
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const labResults = avs => {
if (avs.labResults?.length > 0) {
const labResultItems = avs.labResults.map((item, idx) => (
<div key={idx}>
{labResultValues(item.values)}