import { h } from 'preact'; import PropTypes from 'prop-types'; const orgOptions = (organizations, organizationId) => { const orgs = organizations.map(organization => { if (organizationId === organization.id) { return ( ); } return ; }); const nullOrgOption = organizationId === null ? ( ) : ( ); orgs.unshift(nullOrgOption); // make first option as "None" return orgs; }; const OrgSettings = ({ organizations, organizationId, onToggle }) => (