diff --git a/src/plugins/GenericPageWithIcon.js b/src/plugins/GenericPageWithIcon.js
new file mode 100644
index 0000000..b24a221
--- /dev/null
+++ b/src/plugins/GenericPageWithIcon.js
@@ -0,0 +1,32 @@
+import React from "react";
+import PropTypes from "prop-types";
+import { Box, Button, Heading, Text } from "grommet";
+
+function GenericPageWithIcon(props) {
+ return (
+
+ {props.icon}
+ {props.title}
+ {props.description}
+
+
+ );
+}
+
+GenericPageWithIcon.propTypes = {
+ title: PropTypes.string,
+ description: PropTypes.string,
+ icon: PropTypes.node,
+ close: PropTypes.func
+};
+
+export default GenericPageWithIcon;
diff --git a/src/plugins/warning.js b/src/plugins/warning.js
index c292a67..84014cf 100644
--- a/src/plugins/warning.js
+++ b/src/plugins/warning.js
@@ -1,25 +1,15 @@
import React from "react";
import PropTypes from "prop-types";
-import { Box, Button, Heading, Text } from "grommet";
+import GenericPageWithIcon from "./GenericPageWithIcon";
import { Alert } from "grommet-icons";
function Warning(props) {
return (
-
-
- {props.data.title}
- {props.data.description}
-
-
- );
+ }
+ />);
}
Warning.propTypes = {