Git Product home page Git Product logo

Comments (4)

NicoledeGreef avatar NicoledeGreef commented on August 13, 2024

was previously implemented as:
image

from smk.

michaelpnelson avatar michaelpnelson commented on August 13, 2024

In version 1.0.5, clusterOption.showCoverageOnHover is false by default. I reviewed our code and we set a default value of false in smk.js (https://github.com/bcgov/smk/blame/375e57ec506dbf097a587c443725d032797b54b0/src/smk.js#L729).

from smk.

michaelpnelson avatar michaelpnelson commented on August 13, 2024

In further testing, I do see that a vector layer's clustering shows coverage on hover when no clusterOption.showCoverageOnHover value is set in smk-config.json. I'll reopen this while I investigate further.

from smk.

michaelpnelson avatar michaelpnelson commented on August 13, 2024

I have a better understanding of this now. My observation of coverage on hover in my last comment was affected by local changes I was making (for bcgov/smk-cli#63) that I didn't think would be related but were a cause.

We set viewer.clusterOption.showCoverageOnHover to false by default in smk.js when we are setting up the structure of the configuration in setupGlobalSMK(). In layer-vector-leaflet.js, in the clusterOptions() function, we then create and populate cluster options. Then when we consume these options in marker-cluster-1.0.6.js, if we haven't specifically set a value, a default of 'true' is used.

layer-vector-leaflet.js was amended to set a value in the options based on the value of showCoverageOnHover, either from the 'viewer' section of smk-config.json, or using the default 'false' set in smk.js. This was fixed in #104, and I've confirmed in local testing that showCoverageOnHover is false unless specifically set to true in smk-config.json in the 'viewer' section.

from smk.

Related Issues (20)

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.