<|start_filename|>demo/sidebars.js<|end_filename|>
module.exports = {
  started: [
    "installation",
    "quick-start",
    "use-the-methods",
    "listen-to-events",
    "subscribe-to-reactive-properties",
  ],
  "examples": [
    "examples/HorizontalScroll",
    "examples/VerticalScroll",
    "examples/Properties",
    "examples/Methods",
    "examples/InfiniteScroll",
  ],
  ...require("./sidebars-api.js")
};


<|start_filename|>demo/src/css/examples.css<|end_filename|>
.examples .items {
  position: relative;
  overflow: scroll;
  width: 100%;
  white-space: nowrap;
  overscroll-behavior: none;
  user-select: none;
  height: 400px;
}
.examples .container {
  display: block;
  position: relative;
  width: 100%;
}
.examples .item {
  overflow: hidden;
  /* margin: 18px 12px 30px 0; */
  width: 180px;
  height: 180px;
  line-height: 180px;
  text-align: center;
  font-weight: bold;
  font-size: 40px;
  border-radius: 3px;
  background-color: #fff;
  border: 1px solid #ccc;
}
.examples .items.horizontal {
  height: auto;
}
.examples .items.horizontal .item {
  display: inline-block;
  margin: 5px;
}
.examples .items.vertical .item {
  margin: 5px;
  width: auto;
}
.examples .buttons {
  position: relative;
  height: 40px;
}
.examples .prev, .examples .next {
  position: absolute;
  top: 0;
  z-index: 10;
  border: 1px solid #ccc;
  padding: 5px 20px;
  font-weight: bold;
}

.examples .prev {
  left: 0px;
}

.examples .next {
  right: 0px;
}
/* infinite */
.examples .items.infinite {
  height: 600px;
}
.examples .item.item1 {
  height: 250px;
  line-height: 250px;
}
.examples .item.item2 {
  height: 230px;
  line-height: 230px;
}
.examples .item.item3 {
  height: 270px;
  line-height: 270px;
}
.examples .item.item4 {
  height: 215px;
  line-height: 215px;
}


<|start_filename|>packages/react-conveyer/src/App.css<|end_filename|>
body {
  background: #F0F3FB;
  margin-left: 0;
  margin-right: 0;
}

.items {
  position: relative;
  overflow: scroll;
  width: 100%;
  white-space: nowrap;
  overscroll-behavior: none;
  user-select: none;
  height: 400px;
  border: 1px solid black;
}
.container {
  display: block;
  position: relative;
  width: 100%;

}

.item {
  overflow: hidden;
  margin: 18px 12px 30px 0;
  width: 271px;
  height: 244px;
  line-height: 244px;
  text-align: center;
  font-weight: bold;
  font-size: 40px;
  border-radius: 3px;
  background-color: #fff;
  -webkit-box-shadow: 0 2px 2px 0 rgb(0 0 0 / 4%), 0 0 2px 0 rgb(0 0 0 / 15%);
  box-shadow: 0 2px 2px 0 rgb(0 0 0 / 4%), 0 0 2px 0 rgb(0 0 0 / 15%);
}

#prev,
#next {
  position: absolute;
  top: 0;
  z-index: 10;
}

#prev {
  left: 100px;
}

#next {
  right: 100px;
}


<|start_filename|>packages/react-conveyer/rollup.config.js<|end_filename|>

// conveyer.js
// conveyer.min.js
// conveyer.pkgd.js
// conveyer.pkgd.min.js
// conveyer.esm.js


const buildHelper = require("@egjs/build-helper");

export default buildHelper([
	{
		input: "./src/react-conveyer/index.tsx",
		output: "./dist/conveyer.cjs.js",
		format: "cjs",
		exports: "named",
	},
	{
		input: "./src/react-conveyer/index.tsx",
		output: "./dist/conveyer.esm.js",
		format: "esm",
		exports: "named",
	},
]);



<|start_filename|>demo/src/css/scroll-into-view-target.css<|end_filename|>
.scroll-into-view-target {
  position: relative;
  margin: 0px 50px;
  overflow: hidden;
}
.scroll-into-view-target p {
  position: absolute;
  font-size: 15px;
  line-height: 1;
  font-weight: bold;
}
.scroll-into-view-target p.bottom {
  bottom: 0;
}
.scroll-into-view-target .items, .scroll-into-view-target .background-items {
  position: relative;
  white-space: nowrap;
  overscroll-behavior: none;
  user-select: none;
  border: 2px solid #999;
  border-left: 4px solid #faa;
  border-right: 4px solid #aaf;
  width: 50%;
  left: 50%;
  transform: translate(-50%);
  margin: 80px 0px;
  background: #fff;
}
.scroll-into-view-target .items {
  overflow-x: auto;
}
.scroll-into-view-target .background-items {
  position: absolute;
}
.scroll-into-view-target .background-items .item {
  opacity: 0.5;
}

.scroll-into-view-target .background-items:before, .scroll-into-view-target .background-items:after {
  position: absolute;
  top: 100%;
  color: #333;
  font-size: 15px;
  line-height: 1;
  font-weight: bold;
  transform: translate(-50%, 20px);
}
.scroll-into-view-target .background-items:before {
  content: "start";
}
.scroll-into-view-target .background-items:after {
  content: "end";
  left: 100%;
}
.scroll-into-view-target .item {
  display: inline-block;
  width: 120px;
  height: 120px;
  line-height: 120px;
  text-align: center;
  font-weight: bold;
  font-size: 30px;
  border: 1px solid #ccc;
  margin: 10px 5px;
  /* transform: translate(-500px); */
}
.scroll-into-view-target .prev {
  background: #faa;
}
.scroll-into-view-target .start {
  background: #afa;
}
.scroll-into-view-target .end {
  background: #ffa;
}
.scroll-into-view-target .next {
  background: #aaf;
}
.scroll-into-view-target .mark {
  position: absolute;
  left: 0;
  width: 122px;
  top: 40px;
  background: none;
}
.scroll-into-view-target .mark:before {
  position: relative;
  display: block;
  text-align: center;
  width: 100%;
  color: #333;
  font-size: 15px;
  line-height: 1;
  font-weight: bold;
}
.scroll-into-view-target .mark.prev:before {
  content: "prev";
}
.scroll-into-view-target .mark.next:before {
  content: "next";
}
.scroll-into-view-target .mark.start:before {
  content: "start";
}
.scroll-into-view-target .mark.end:before {
  content: "end";
}


<|start_filename|>demo/plugin/glslify.js<|end_filename|>
module.exports = function(context, options) {
  return {
    name: "docusaurus-plugin-glslify",
    configureWebpack() {
      return {
        module: {
          rules: [
            {
              test: /\.(glsl|vs|fs|vert|frag)$/,
              exclude: /node_modules/,
              use: ["raw-loader", "glslify-loader"]
            }
          ]
        }
      };
    }
  };
};


<|start_filename|>packages/vue-conveyer/rollup.config.js<|end_filename|>
const commonjs = require("rollup-plugin-commonjs");
const buildHelper = require("@egjs/build-helper");

export default buildHelper([
	{
		input: "./src/vue-conveyer/index.ts",
		output: "./dist/conveyer.cjs.js",
		format: "cjs",
		exports: "named",
		external: {
			"vue": "vue",
			"@egjs/conveyer": "@egjs/conveyer",
		}
	},
	{
		input: "./src/vue-conveyer/index.ts",
		output: "./dist/conveyer.esm.js",
		format: "esm",
		exports: "named",
		external: {
			"vue": "vue",
			"@egjs/conveyer": "@egjs/conveyer",
		}
	},
]);



<|start_filename|>demo/webpack.js<|end_filename|>
const path = require("path");

module.exports = function (context, options) {
  return {
    name: 'custom-docusaurus-plugin',
    configureWebpack(config, isServer, utils) {
      return {
        resolve: {
          alias: {
            // "@egjs/infinitegrid": path.resolve(__dirname, '../dist/infinitegrid.esm.js'),
          },
        }
      };
    },
  };
};


<|start_filename|>packages/ngx-conveyer/src/styles.css<|end_filename|>
/* You can add global styles to this file, and also import other style files */

html,
body {
  font-family: sans-serif;
}
.examples .items {
  position: relative;
  overflow: scroll;
  width: 100%;
  white-space: nowrap;
  overscroll-behavior: none;
  user-select: none;
  height: 400px;
}
.examples .container {
  display: block;
  position: relative;
  width: 100%;
}
.examples .item {
  overflow: hidden;
  /* margin: 18px 12px 30px 0; */
  width: 180px;
  height: 180px;
  line-height: 180px;
  text-align: center;
  font-weight: bold;
  font-size: 40px;
  border-radius: 3px;
  background-color: #fff;
  border: 1px solid #ccc;
}
.items.horizontal {
  height: auto;
}
.items.horizontal .item {
  display: inline-block;
  margin: 5px;
}
.items.vertical .item {
  margin: 5px;
  width: auto;
}
.examples .buttons {
  position: relative;
  height: 40px;
}
.examples .prev,
.examples .next {
  position: absolute;
  top: 0;
  z-index: 10;
  border: 1px solid #ccc;
  padding: 5px 20px;
  font-weight: bold;
}

.examples .prev {
  left: 0px;
}

.examples .next {
  right: 0px;
}


<|start_filename|>rollup.config.js<|end_filename|>

const buildHelper = require("@egjs/build-helper");
const name = "Conveyer";

export default buildHelper([
	{
		name,
		input: "./src/index.umd.ts",
		output: "./dist/conveyer.js",
		format: "umd",
		resolve: true,
	},
	{
		name,
		input: "./src/index.umd.ts",
		output: "./dist/conveyer.min.js",
		format: "umd",
		uglify: true,
		resolve: true,
	},
	{
		input: "./src/index.umd.ts",
		output: "./dist/conveyer.cjs.js",
		format: "cjs",
		exports: "default",
	},
	{
		input: "./src/index.ts",
		output: "./dist/conveyer.esm.js",
		format: "esm",
		exports: "named",
	},
]);

