add mockup for content classes

This commit is contained in:
Maren Süwer
2018-10-15 16:45:54 +02:00
parent af81f239e1
commit c23fa319a0
6 changed files with 181 additions and 0 deletions

View File

@@ -0,0 +1,39 @@
// @flow
import React from "react";
import { translate } from "react-i18next";
import { apiClient } from "@scm-manager/ui-components";
type Props = {
t: string => string
};
type State = {
contentType: string
};
class Content extends React.Component<Props, State> {
constructor(props: Props) {
super(props);
this.state = {
contentType: ""
};
}
componentDidMount() {}
render() {
return null;
}
}
export function getContentType(url: string) {
return apiClient
.head(url)
.then(response => response)
.catch(err => {
return null;
});
}
export default translate("repos")(Content);