Files
frontend-app-profile/src/profile-v2/forms/elements/EmptyContent.jsx
Awais Ansari 762e29047f feat: merge 2u-main into master (#1231)
* feat: added country disabling feature (#1084)

* feat: added country disabling feature

* fix: lint errors

* test: added test case for disabled countries

* refactor: combined test cases

* feat: reskin of Profile MFE main page (#1114)

* feat: reskin of Profile MFE main page

* feat: reskin of Profile MFE main page

* test: updated tests according to the changes

* fix: added missing name property

* test: updated test snapshot

* test: added tests for reducers

* feat: moved reskin logic behind env variable

* test: updated tests

* refactor: refactored code according to requested changes

* fix: fixed lint errors

* refactor: refactored code according to requested changes

* refactor: refactored code according to requested changes

* feat: fixed reloading issue

* fix: fixed responsiveness issues on mobile view (#1133)

* fix: fixed reponsiveness issues on mobile view

* test: updated tests

* refactor: refactored code as requested

* test: added not found test case

* test: updated test cases

* feat: added restricted country functionality

* fix: fixed test cases

* test: updated snapshot

* test: updated test cases

* feat: made profile editable (#1212)

* feat: readded editable fields to new profile view

* feat: made fullname editable and updated design

* test: updated test cases

* refactor: refactored code based on reviews

* feat: made fullname uneditable and added redirect link (#1215)

* feat: made fullname uneditable and added redirect link

* refactor: refactored code

* refactor: refactored code

* chore: rebase 2u-main with master (#1225)

* fix(deps): update dependency @edx/frontend-platform to v8.3.3 (#1187)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix(deps): update dependency core-js to v3.41.0 (#1188)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update `@openedx` dependencies to versions that support React 18 (#1189)

* chore(deps): update dependency @openedx/frontend-build to v14.4.1 (#1191)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix(deps): update react-router monorepo to v6.30.0 (#1192)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* feat: upgrade react to v18 (#1190)

* fix(deps): update dependency @edx/frontend-platform to v8.3.4 (#1195)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix(deps): update dependency @edx/frontend-component-footer to v14.4.0 (#1196)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix(deps): update dependency @edx/frontend-component-header to v6.3.0 (#1197)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix(deps): update dependency @edx/frontend-component-footer to v14.6.0 (#1199)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix(deps): update dependency @edx/openedx-atlas to ^0.7.0 (#1200)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix(deps): update dependency @edx/frontend-component-header to v6.4.0 (#1201)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* feat: import `FooterSlot` from component package instead of slot package (#1198)

* chore(deps): update dependency glob to v11.0.2 (#1202)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix(deps): update dependency @edx/frontend-component-footer to v14.7.0 (#1203)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix(deps): update dependency @edx/frontend-component-footer to v14.7.1 (#1204)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix(deps): update dependency core-js to v3.42.0 (#1205)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix(deps): update dependency @edx/frontend-platform to v8.3.6 (#1207)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update commitlint monorepo to v19.8.1 (#1206)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix(deps): update dependency @edx/frontend-platform to v8.3.7 (#1209)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix(deps): update dependency @edx/frontend-component-footer to v14.7.2 (#1213)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix(deps): update react-router monorepo to v6.30.1 (#1214)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix(deps): update dependency @edx/frontend-platform to v8.3.9 (#1216)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix(deps): update dependency @edx/frontend-component-footer to v14.9.0 (#1217)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* feat!: add design tokens support (#1220)

BREAKING CHANGE: Pre-design-tokens theming is no longer supported.

Co-authored-by: Diana Olarte <diana.olarte@edunext.co>

* fix: fixed lint issues

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Brian Smith <112954497+brian-smith-tcril@users.noreply.github.com>
Co-authored-by: Hunia Fatima <huniafatima99@gmail.com>
Co-authored-by: Diana Olarte <diana.olarte@edunext.co>
Co-authored-by: sundasnoreen12 <sundasnoreen12@gmail.com>

* fix: fixed font sizing issue after applying elm theme (#1228)

* Revert "fix: fixed font sizing issue after applying elm theme (#1228)" (#1232)

This reverts commit a9159f6613.

---------

Co-authored-by: muhammadadeeltajamul <muhammadadeeltajamul@hotmail.com>
Co-authored-by: Muhammad Adeel Tajamul <77053848+muhammadadeeltajamul@users.noreply.github.com>
Co-authored-by: Eemaan Amir <57627710+eemaanamir@users.noreply.github.com>
Co-authored-by: sundasnoreen12 <sundasnoreen12@gmail.com>
Co-authored-by: sundasnoreen12 <72802712+sundasnoreen12@users.noreply.github.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Brian Smith <112954497+brian-smith-tcril@users.noreply.github.com>
Co-authored-by: Hunia Fatima <huniafatima99@gmail.com>
Co-authored-by: Diana Olarte <diana.olarte@edunext.co>
Co-authored-by: eemaanamir <eemaan.amir@gmail.com>
2025-07-10 10:12:21 +05:00

36 lines
911 B
JavaScript

import React from 'react';
import PropTypes from 'prop-types';
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
import { faPlus } from '@fortawesome/free-solid-svg-icons';
const EmptyContent = ({ children, onClick, showPlusIcon }) => (
<div className="p-0 m-0">
{onClick ? (
<button
type="button"
className="p-0 text-left btn btn-link lh-36px"
onClick={onClick}
onKeyDown={(e) => { if (e.key === 'Enter') { onClick(); } }}
tabIndex={0}
>
{showPlusIcon ? <FontAwesomeIcon size="xs" className="mr-1" icon={faPlus} /> : null}
{children}
</button>
) : children}
</div>
);
export default EmptyContent;
EmptyContent.propTypes = {
onClick: PropTypes.func,
children: PropTypes.node,
showPlusIcon: PropTypes.bool,
};
EmptyContent.defaultProps = {
onClick: null,
children: null,
showPlusIcon: true,
};