Select a picture
; 27 | 28 | 29 | let typeExtra: string; 30 | switch (type) { 31 | case 2: 32 | typeExtra = "?grayscale"; 33 | break; 34 | case 3: 35 | typeExtra = "?blur"; 36 | break; 37 | case 4: 38 | typeExtra = "?grayscale&blur=2"; 39 | break; 40 | case 5: 41 | typeExtra = "?grayscale&blur=5"; 42 | break; 43 | case 1: 44 | default: 45 | typeExtra = ""; 46 | break; 47 | } 48 | 49 | return ; 55 | } 56 | } -------------------------------------------------------------------------------- /example/app/components/pictures-list/PicturesListComponent.tsx: -------------------------------------------------------------------------------- 1 | import { observer } from "mobx-react"; 2 | import React from "react"; 3 | import { injectFromApp } from "../../App"; 4 | import { IPicturesStore } from "../../stores/PicturesStore"; 5 | import { PicturesListPictureComponent } from "./PicturesListPictureComponent"; 6 | 7 | export interface IPicturesListComponentProps { 8 | picturesStore?: IPicturesStore 9 | } 10 | 11 | @injectFromApp