import React from 'react'; import { pathUtils } from '@growi/core/dist/utils'; import { useTranslation } from 'next-i18next'; import PropTypes from 'prop-types'; import { Modal, ModalHeader, ModalBody } from 'reactstrap'; import urljoin from 'url-join'; const CreateTemplateModal = (props) => { const { t } = useTranslation(); const { path } = props; const parentPath = pathUtils.addTrailingSlash(path); function generateUrl(label) { return encodeURI(urljoin(parentPath, label, '#edit')); } /** * @param {string} target Which hierarchy to create [children, decendants] */ function renderTemplateCard(target, label) { return (
); } return (