Code Monkey home page Code Monkey logo

vue-read-more-smooth's Introduction

vue-read-more-smooth

license vue 2 npm npm

"Read more" button with animation and easy usage for vuejs.

Install

Via npm:

npm

npm install vue-read-more-smooth --save

Via Yarn:

yarn add vue-read-more-smooth

Demo & examples

Code examples: https://dicren.github.io/vue-read-more-smooth/

Usage

<template>
  <VueReadMoreSmooth>
    <p>Lorem Ipsum</p>
  </VueReadMoreSmooth>
</template>
<script>
  import VueReadMoreSmooth from "vue-read-more-smooth";
  export default {
    name: "app",
    components: { VueReadMoreSmooth }
  }
</script>

Properties

Property Type Default Description
:lines number 3 Number of lines to show before the read more button.
:g-lines number 2 Shadow's size. If lines is greater than 12, g-lines default value is 4, if lines is greater than 6, g-lines default value is 3
:max-lines number lines + 1 If your text has less than max-lines, the container acts as a normal div.
:text string Read more obvious
:text-less string Read less obvious
:no-less boolean false if true button disappear after click read more
:open boolean false open and close programmatically. .sync is available.
:no-button boolean false Hide the button. To use in combination with :open
:no-shadow boolean false Hide the shadow.

Changelog

0.1.8 - 2019-08-09

Added

  • :open property
  • :no-button property
  • :no-shadow property

Removed

  • :open-by-default property, replaced by :open

License

MIT


⌨️ with ❤️ by dicren

vue-read-more-smooth's People

Contributors

dependabot[bot] avatar dicren avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.