Skip to content

Commit 596b425

Browse files
Ori AmirOri Amir
authored andcommitted
new: select
1 parent 4d5a2c9 commit 596b425

8 files changed

Lines changed: 10990 additions & 1330 deletions

File tree

dist/index.bundle.js

Lines changed: 12 additions & 28 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,6 @@
1212

1313
<body>
1414
<div id="app"></div>
15-
<script type="text/javascript" src="index.bundle.js?c2e5caa42137f852fa71"></script></body>
15+
<script type="text/javascript" src="index.bundle.js?fb11b288cbb75133944d"></script></body>
1616

1717
</html>

package-lock.json

Lines changed: 10959 additions & 1105 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,13 +40,12 @@
4040
"css-loader": "^2.1.1",
4141
"eslint-plugin-react-hooks": "^1.6.0",
4242
"express": "^4.17.1",
43-
"node-sass": "^4.14.1",
4443
"prop-types": "^15.7.2",
4544
"react": "^16.8.6",
4645
"react-bootstrap": "^1.0.0-beta.9",
4746
"react-dom": "^16.8.6",
48-
"react-image-lightbox": "^5.1.0",
49-
"react-responsive-gallery": "^2.0.1",
47+
"react-responsive-gallery": "^2.1.1",
48+
"sass": "^1.51.0",
5049
"sass-loader": "^7.1.0",
5150
"shortid": "^2.2.14",
5251
"style-loader": "^0.23.1",

src/components/app.js

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ import {
1414
} from '../constants/responsive';
1515
import useDefaultScreenDimensions from '../hooks/use-default-screen-dimensions';
1616
import { getSizeGroup } from '../utils/gallery';
17-
// import GalleryTest from './gallery';
1817

1918
const App = () => {
2019
const [screenWidthSizes, setScreenWidthValues] = useState(screenWidthSizesDefault);
@@ -24,6 +23,7 @@ const App = () => {
2423
const width = useDefaultScreenDimensions();
2524
const [showoptions, setShowOptions] = useState(true);
2625
const [useLightBox, setUseLightBox] = useState(false);
26+
const [selectable, setSelectable] = useState(false);
2727

2828
return (
2929
<div className={styles.generalApp}>
@@ -65,7 +65,14 @@ const App = () => {
6565
<input value={useLightBox} onChange={e => setUseLightBox(e.target.checked)} type="checkbox" />
6666
</span>
6767
</Col>
68-
68+
</Row>
69+
<Row>
70+
<Col className={styles.checkBoxLabel}>
71+
Use Images selectable:
72+
<span className={styles.checkBoxInput}>
73+
<input value={selectable} onChange={e => setSelectable(e.target.checked)} type="checkbox" />
74+
</span>
75+
</Col>
6976
</Row>
7077
<Row>
7178
<Col xs={12} sm={6} md={3} lg={3} xl={3}>
@@ -176,15 +183,12 @@ const App = () => {
176183
},
177184
{
178185
src: 'https://cdn.pixabay.com/photo/2017/03/31/15/41/giraffe-2191662_1280.jpg'
179-
// orderS: 1,
180-
// orderM: 2,
181-
// orderL: 3,
182-
// imgClassName: styles.test1 }
183186
}]}
184187
screenWidthSizes={screenWidthSizes}
185188
numOfImagesPerRow={numOfImagePerRow}
186189
imagesPaddingBottom={imagesPaddingBottom}
187190
imagesMaxWidth={imagesMaxWidth}
191+
selectable={selectable}
188192
// colsPadding={{
189193
// xs: 5, s: 10, m: 15, l: 20, xl: 25, xxl: 50
190194
// }}

src/components/gallery.js

Lines changed: 0 additions & 136 deletions
This file was deleted.

src/components/images-light-box.js

Lines changed: 0 additions & 38 deletions
This file was deleted.

src/index.js

Lines changed: 6 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,8 @@
1-
import React from 'react';
2-
import { render } from 'react-dom';
3-
import './assets/style.scss';
4-
import 'react-image-lightbox/style.css'; // This only needs to be imported once in your app
1+
import React from "react";
2+
import { render } from "react-dom";
3+
import "./assets/style.scss";
4+
import App from "./components/app";
55

6-
// import GalleryTest from './components/gallery';
7-
// import styles from './app.module.scss';
8-
import App from './components/app';
6+
const rootEl = document.getElementById("app");
97

10-
const rootEl = document.getElementById('app');
11-
12-
render(
13-
<App />,
14-
rootEl
15-
);
8+
render(<App />, rootEl);

0 commit comments

Comments
 (0)