コミット
af22c3a16b
長すぎる行があるためファイル差分は表示されません
長すぎる行があるためファイル差分は表示されません
|
@ -7,13 +7,14 @@ const Alert = (props) => {
|
|||
|
||||
useEffect(() => {
|
||||
window.scrollTo(0, 0);
|
||||
let timer = setTimeout(()=>{
|
||||
clearTimeout(timer);
|
||||
if(props.hide) props.hide();
|
||||
}, 5000)
|
||||
const element = `<div class="alert-${props.type} ft-18 ft-xs-16" id="alert-wrapper">`+
|
||||
props.children +
|
||||
'</div>';
|
||||
document.getElementById('alert').innerHTML = element;
|
||||
if(props.hide) props.hide();
|
||||
},[]);
|
||||
|
||||
return (
|
||||
return (
|
||||
<div className={`alert-${props.type} ft-18 ft-xs-16`}>
|
||||
{props.children}
|
||||
</div>
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
color: #fff;
|
||||
font-weight: 700;
|
||||
border-radius: 0;
|
||||
z-index: 1000;
|
||||
z-index: 99999;
|
||||
// duration | timing-function | delay | iteration-count | direction | fill-mode | play-state | name
|
||||
animation: 1s ease-out 4s 1 normal forwards running fadeOut;
|
||||
-moz-animation: 1s ease-out 4s 1 normal forwards running fadeOut;
|
||||
|
|
|
@ -40,6 +40,7 @@
|
|||
</head>
|
||||
|
||||
<body>
|
||||
<div id="alert"></div>
|
||||
<div id="root"></div>
|
||||
@yield('content')
|
||||
</body>
|
||||
|
|
新しいイシューから参照