How to use the @entando/utils.formattedText function in @entando/utils

To help you get started, we’ve selected a few @entando/utils examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github entando / app-builder / src / state / file-browser / actions.js View on Github external
}).catch(() => {
      dispatch(addToast(formattedText('fileBrowser.createFolderError', null, { path: values.path }), TOAST_ERROR));
    });
  })
github entando / app-builder / src / ui / pages / config / ContentWidget.js View on Github external
onKeyDown={() => changeViewList('card')}
            onClick={() => changeViewList('card')}
          />
          <i tabindex="{-2}" role="button"> changeViewList('list')}
            onClick={() =&gt; changeViewList('list')}
          /&gt;
        
        <input placeholder="{formattedText('app.search')}" type="text">
      
      <div>
        {renderComponent(widgetList)}
      </div>
    
  );
};
</i>
github entando / app-builder / src / state / digital-exchange / components / actions.js View on Github external
.catch((res) => {
        const {
          errors,
          payload,
        } = res;
        if (payload && payload.status === DE_COMPONENT_INSTALLATION_STATUS_IN_PROGRESS) {
          dispatch(addToast(
            formattedText('digitalExchange.components.notifyInProgress'),
            TOAST_WARNING,
          ));
          dispatch(componentUninstallOngoingProgress(componentId));
        } else {
          dispatch(addToast(
            formattedText('digitalExchange.components.notifyFailedUninstall'),
            TOAST_WARNING,
          ));
          dispatch(componentUninstallFailed(componentId));
        }
        if (errors && errors.length) {
          dispatch(addErrors(errors.map(err => err.message)));
        }
        resolve(res);
      })
      .finally(() => resolve());
github entando / app-builder / src / ui / pages / config / PageConfigPage.js View on Github external
bsStyle="default"
                      onClick={this.toggleInfoTable}
                    &gt;
                      <span>
                        
                        
                      </span>
                    
                  
                  
                    <a rel="noopener noreferrer" title="{formattedText('app.preview'," href="{previewUri}">
                      
                    </a>
github entando / app-builder / src / ui / groups / detail / GroupDetailTabUsers.js View on Github external
renderRows() {
    const editUser = formattedText('app.edit');
    const authority = formattedText('group.action.manageAuthorization');
    const statusIconClass = status =&gt; (status === 'active' ? 'GroupDetailTabUsers__status-icon--active' : 'GroupDetailTabUsers__status-icon--disabled');

    return this.props.userReferences.map(item =&gt; (
      
        {item.profileAttributes.fullname || item.username}
        {item.lastLogin}
        
          <i>
        
        
          
            </i>
github entando / app-builder / src / ui / fragments / common / FragmentForm.js View on Github external
disabled={mode === EDIT_MODE}
            /&gt;
            {widgetTypeField}
            {pluginField}
          
        
      
      <hr>
      
        
          <fieldset>
            <div>
              <span>
              
                
                  
                    <div>
                      <div>
                        
                      </div>
                    </div>
                  
                  
                    {defaultGuiCodeField}
                  </span></div></fieldset>
github entando / entando-components / plugins / entando-plugin-dashboard / app-builder / src / ui / server-config / common / ServerConfigForm.js View on Github external
<fieldset>
              }
                placeholder={formattedText('ServerConfigForm.name')}
                validate={[required]}
              /&gt;
            </fieldset>
            <fieldset>
              }
                placeholder={formattedText('ServerConfigForm.hostName')}
                validate={[required]}
              /&gt;
            </fieldset>

            <fieldset>
              }
                placeholder={formattedText('ServerConfigForm.schema')}
                validate={[required]}
              /&gt;
            </fieldset>
            <fieldset>
              </fieldset>
github entando / app-builder / src / ui / widgets / common / WidgetForm.js View on Github external
};

    let codeField = (
      
        }
        placeholder={formattedText('widget.page.create.code.placeholder')}
        validate={[required, widgetCode, maxLength30]}
      /&gt;
    );

    let defaultUITab = (
      
        {
          this.props.defaultUIField ? this.props.defaultUIField :
          
            
          
        }
      
    );

    if (this.props.mode === 'edit') {
      codeField = null;
    } else {
      defaultUITab = null;
    }

    return (
github entando / app-builder / src / ui / file-browser / common / CreateTextFileForm.js View on Github external
<option value=".txt">txt</option>
                      <option value=".css">css</option>
                    
                  
              : null
            }
        
        
          

            

          
        
        
          
            <button disabled="{invalid" type="submit">
              
            </button>
github entando / app-builder / src / ui / users / common / const.js View on Github external
import { formattedText } from '@entando/utils';

export const PROFILE_FILTER_OPTIONS = [
  {
    id: 'all',
    label: formattedText('user.profile.all'),
  },
  {
    id: 'with',
    label: formattedText('user.profile.with'),
  },
  {
    id: 'without',
    label: formattedText('user.profile.without'),
  },
];
export const BOOLEAN_OPTIONS = [
  {
    id: 'true',
    label: formattedText('app.booleanOptions.true'),
  },
  {
    id: 'false',
    label: formattedText('app.booleanOptions.false'),
  },
];